Skip to content

Commit 0284283

Browse files
committed
Separate the module version from module source when using ?ref=
Signed-off-by: Edgar R. Sandi <edgar.r.sandi@gmail.com>
1 parent fdaa645 commit 0284283

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+207
-15
lines changed

docs/reference/asciidoc-document.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,12 @@ generates the following output:
137137

138138
Version: 1.2.3
139139

140+
=== [[module_foobar]] <<module_foobar,foobar>>
141+
142+
Source: git@github.com:module/path
143+
144+
Version: v7.8.9
145+
140146
== Resources
141147

142148
The following resources are used by this module:

docs/reference/asciidoc-table.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ generates the following output:
122122
|[[module_bar]] <<module_bar,bar>>|baz|4.5.6
123123
|[[module_baz]] <<module_baz,baz>>|baz|4.5.6
124124
|[[module_foo]] <<module_foo,foo>>|bar|1.2.3
125+
|[[module_foobar]] <<module_foobar,foobar>>|git@github.com:module/path|v7.8.9
125126
|===
126127

127128
== Resources

docs/reference/json.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,11 @@ generates the following output:
312312
"name": "foo",
313313
"source": "bar",
314314
"version": "1.2.3"
315+
},
316+
{
317+
"name": "foobar",
318+
"source": "git@github.com:module/path",
319+
"version": "v7.8.9"
315320
}
316321
],
317322
"outputs": [

docs/reference/markdown-document.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,12 @@ generates the following output:
138138

139139
Version: 1.2.3
140140

141+
### <a name="module_foobar"></a> [foobar](#module\_foobar)
142+
143+
Source: git@github.com:module/path
144+
145+
Version: v7.8.9
146+
141147
## Resources
142148

143149
The following resources are used by this module:

docs/reference/markdown-table.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ generates the following output:
118118
| <a name="module_bar"></a> [bar](#module\_bar) | baz | 4.5.6 |
119119
| <a name="module_baz"></a> [baz](#module\_baz) | baz | 4.5.6 |
120120
| <a name="module_foo"></a> [foo](#module\_foo) | bar | 1.2.3 |
121+
| <a name="module_foobar"></a> [foobar](#module\_foobar) | git@github.com:module/path | v7.8.9 |
121122

122123
## Resources
123124

docs/reference/pretty.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ generates the following output:
103103
module.bar (baz,4.5.6)
104104
module.baz (baz,4.5.6)
105105
module.foo (bar,1.2.3)
106+
module.foobar (git@github.com:module/path,v7.8.9)
106107

107108

108109
resource.null_resource.foo (resource) (https://registry.terraform.io/providers/hashicorp/null/latest/docs/resources/resource)

docs/reference/toml.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,11 @@ generates the following output:
296296
source = "bar"
297297
version = "1.2.3"
298298

299+
[[modules]]
300+
name = "foobar"
301+
source = "git@github.com:module/path"
302+
version = "v7.8.9"
303+
299304
[[outputs]]
300305
name = "output-0.12"
301306
description = "terraform 0.12 only"

docs/reference/xml.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,11 @@ generates the following output:
312312
<source>bar</source>
313313
<version>1.2.3</version>
314314
</module>
315+
<module>
316+
<name>foobar</name>
317+
<source>git@github.com:module/path</source>
318+
<version>v7.8.9</version>
319+
</module>
315320
</modules>
316321
<outputs>
317322
<output>

docs/reference/yaml.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,6 +285,9 @@ generates the following output:
285285
- name: foo
286286
source: bar
287287
version: 1.2.3
288+
- name: foobar
289+
source: git@github.com:module/path
290+
version: v7.8.9
288291
outputs:
289292
- name: output-0.12
290293
description: terraform 0.12 only

examples/main.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,3 +72,7 @@ module "baz" {
7272
source = "baz"
7373
version = "4.5.6"
7474
}
75+
76+
module "foobar" {
77+
source = "git@github.com:module/path?ref=v7.8.9"
78+
}

0 commit comments

Comments
 (0)