terradoc 0.1.5 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -1
- data/README.md +4 -0
- data/TEST +87 -0
- data/VERSION.txt +1 -1
- data/lib/terradoc.rb +4 -4
- data/lib/terradoc/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f8d4b322dd69ee236532a345bca8ac90f081197f724c647db1d5ac65ba720bab
|
|
4
|
+
data.tar.gz: 11b18b4769f977988a0b8bb277d35b4f495641b2f75483604f4aaad15317c958
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e4a00858f0dc2061fbde8b6159b23682855d4162e6c2114a78f945a4e6e8cd7ef5e39ef71974043598d5b9e6d59c72ffe246687932613a8698ee0a6dd0f39ff9
|
|
7
|
+
data.tar.gz: 8aff03b52debea2854e0a0c7152f9a3f63c1be87e117d95f7360d81b0ed9685734277252ac433a1169756c7119518761dd178db80d549184eace019afbb57ad2
|
data/CHANGELOG.md
CHANGED
|
@@ -5,11 +5,17 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
|
|
6
6
|
This changelog was automatically generated using [Caretaker](https://github.com/TerraformToolbox/terradoc) by [Wolf Software](https://github.com/WolfSoftware)
|
|
7
7
|
|
|
8
|
+
### [v0.1.6](https://github.com/TerraformToolbox/terradoc/compare/v0.1.5...v0.1.6)
|
|
9
|
+
|
|
10
|
+
> Released on March, 18th 2020
|
|
11
|
+
|
|
12
|
+
- Fixed a bug in 'Required' for variables, and increased the nesting level for json parse for deep nested code [`[4c7d6b4]`](https://github.com/TerraformToolbox/terradoc/commit/4c7d6b4f9fa7bf83d7d61a27c6dc3bd42e2c4dc0) [`[TGWolf]`](https://github.com/TGWolf)
|
|
13
|
+
|
|
8
14
|
### [v0.1.5](https://github.com/TerraformToolbox/terradoc/compare/v0.1.4...v0.1.5)
|
|
9
15
|
|
|
10
16
|
> Released on March, 18th 2020
|
|
11
17
|
|
|
12
|
-
- Update the readme ready for release [`[
|
|
18
|
+
- Update the readme ready for release [`[5d370ce]`](https://github.com/TerraformToolbox/terradoc/commit/5d370ceec1df0ed3b519ad51a3fdddf708e6565c) [`[TGWolf]`](https://github.com/TGWolf)
|
|
13
19
|
|
|
14
20
|
- Fairly big internal review to make use of hcl2json, and additional outputs [`[b528f93]`](https://github.com/TerraformToolbox/terradoc/commit/b528f9385eb98ee4756f7feb9c2a9b481e302ff8) [`[TGWolf]`](https://github.com/TGWolf)
|
|
15
21
|
|
data/README.md
CHANGED
|
@@ -82,6 +82,10 @@ There are a number tags that you need to add to your README in order for terrado
|
|
|
82
82
|
|
|
83
83
|
Now you can simply run ```terradoc``` and it will generate the output.
|
|
84
84
|
|
|
85
|
+
## Known Errors
|
|
86
|
+
|
|
87
|
+
If you see an error similiar to ```Error: nesting of 257 is too deep ``` then you should review your code as you have very high levels of nesting. The code will cope with 256 levels.
|
|
88
|
+
|
|
85
89
|
## Contributing to Terradoc
|
|
86
90
|
|
|
87
91
|
### Setup
|
data/TEST
ADDED
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# Some example README
|
|
2
|
+
|
|
3
|
+
## Data Sources
|
|
4
|
+
<!--Terradoc-data-sources-start-->
|
|
5
|
+
> No data found
|
|
6
|
+
<!--Terradoc-data-sources-end-->
|
|
7
|
+
|
|
8
|
+
## Modules
|
|
9
|
+
<!--Terradoc-modules-start-->
|
|
10
|
+
> No data found
|
|
11
|
+
<!--Terradoc-modules-end-->
|
|
12
|
+
|
|
13
|
+
## Outputs
|
|
14
|
+
<!--Terradoc-outputs-start-->
|
|
15
|
+
| Name | Description |
|
|
16
|
+
| ---- | ----------- |
|
|
17
|
+
| automated\_testing\_account\_alias | The account alias for the automated testing account |
|
|
18
|
+
| automated\_testing\_account\_email | The account email for the automated testing account |
|
|
19
|
+
| automated\_testing\_account\_id | The account id for the automated testing account |
|
|
20
|
+
| automated\_testing\_account\_name | The account name for the automated testing account |
|
|
21
|
+
| development\_account\_alias | The account alias for the development account |
|
|
22
|
+
| development\_account\_email | The account email for the development account |
|
|
23
|
+
| development\_account\_id | The account id for the development account |
|
|
24
|
+
| development\_account\_name | The account name for the development account |
|
|
25
|
+
| development\_collector\_account\_alias | The account alias for the development collect account |
|
|
26
|
+
| development\_collector\_account\_email | The account email for the development collect account |
|
|
27
|
+
| development\_collector\_account\_id | The account id for the development collect account |
|
|
28
|
+
| development\_collector\_account\_name | The account name for the development collect account |
|
|
29
|
+
| infradev\_account\_alias | The account alias for the infradev account |
|
|
30
|
+
| infradev\_account\_email | The account email for the infradev account |
|
|
31
|
+
| infradev\_account\_id | The account id for the infradev account |
|
|
32
|
+
| infradev\_account\_name | The account name for the infradev account |
|
|
33
|
+
| logging\_account\_alias | The account alias for the logging account |
|
|
34
|
+
| logging\_account\_email | The account email for the logging account |
|
|
35
|
+
| logging\_account\_id | The account id for the logging account |
|
|
36
|
+
| logging\_account\_name | The account id for the logging account |
|
|
37
|
+
| messaging\_account\_alias | The account alias for the messaging account |
|
|
38
|
+
| messaging\_account\_email | The account email for the messaging account |
|
|
39
|
+
| messaging\_account\_id | The account id for the messaging account |
|
|
40
|
+
| messaging\_account\_name | The account name for the messaging account |
|
|
41
|
+
| organisation\_account\_alias | The account alias for the organisation account |
|
|
42
|
+
| organisation\_account\_email | The account email for the organisation account |
|
|
43
|
+
| organisation\_account\_id | The account id for the organisation account |
|
|
44
|
+
| organisation\_account\_name | The account name for the organisation account |
|
|
45
|
+
| production\_account\_alias | The account alias for the production account |
|
|
46
|
+
| production\_account\_email | The account email for the production account |
|
|
47
|
+
| production\_account\_id | The account id for the production account |
|
|
48
|
+
| production\_account\_name | The account name for the production account |
|
|
49
|
+
| production\_collector\_account\_alias | The account alias for the production collector account |
|
|
50
|
+
| production\_collector\_account\_email | The account email for the production collector account |
|
|
51
|
+
| production\_collector\_account\_id | The account id for the production collector account |
|
|
52
|
+
| production\_collector\_account\_name | The account name for the production collector account |
|
|
53
|
+
| reporting\_account\_alias | The account alias for the reporting account |
|
|
54
|
+
| reporting\_account\_email | The account email for the reporting account |
|
|
55
|
+
| reporting\_account\_id | The account id for the reporting account |
|
|
56
|
+
| reporting\_account\_name | The account name for the reporting account |
|
|
57
|
+
| testing\_account\_alias | The account alias for the testing account |
|
|
58
|
+
| testing\_account\_email | The account email for the testing account |
|
|
59
|
+
| testing\_account\_id | The account id for the testing account |
|
|
60
|
+
| testing\_account\_name | The account name for the testing account |
|
|
61
|
+
| testing\_collector\_account\_alias | The account alias for the testing collector account |
|
|
62
|
+
| testing\_collector\_account\_email | The account email for the testing collector account |
|
|
63
|
+
| testing\_collector\_account\_id | The account id for the testing collector account |
|
|
64
|
+
| testing\_collector\_account\_name | The account name for the testing collector account |
|
|
65
|
+
| tooling\_account\_alias | The account alias for the tooling account |
|
|
66
|
+
| tooling\_account\_email | The account email for the tooling account |
|
|
67
|
+
| tooling\_account\_id | The account id for the tooling account |
|
|
68
|
+
| tooling\_account\_name | The account name for the tooling account |
|
|
69
|
+
<!--Terradoc-outputs-end-->
|
|
70
|
+
|
|
71
|
+
## Providers
|
|
72
|
+
<!--Terradoc-providers-start-->
|
|
73
|
+
<!--Terradoc-providers-end-->
|
|
74
|
+
|
|
75
|
+
## Resources
|
|
76
|
+
<!--Terradoc-resources-start-->
|
|
77
|
+
> No data found
|
|
78
|
+
<!--Terradoc-resources-end-->
|
|
79
|
+
|
|
80
|
+
## Variables
|
|
81
|
+
<!--Terradoc-variables-start-->
|
|
82
|
+
| Name | Description | Type | Default | Required? |
|
|
83
|
+
| ---- | ----------- |:----:|:-------:|:---------:|
|
|
84
|
+
| account\_emails | A list of account email addresses | list(string) | | Yes |
|
|
85
|
+
| account\_ids | A list of account id | list(string) | | Yes |
|
|
86
|
+
| account\_names | A list of account names | list(string) | | Yes |
|
|
87
|
+
<!--Terradoc-variables-end-->
|
data/VERSION.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.1.
|
|
1
|
+
0.1.6
|
data/lib/terradoc.rb
CHANGED
|
@@ -141,7 +141,7 @@ class Terradoc
|
|
|
141
141
|
Open3.popen3("hcl2json #{file}") do |_stdin, stdout, _stderr, _wait_thr|
|
|
142
142
|
stdout_str = stdout.read
|
|
143
143
|
|
|
144
|
-
json = JSON.parse(stdout_str)
|
|
144
|
+
json = JSON.parse(stdout_str, max_nesting: 256)
|
|
145
145
|
@raw_results = @raw_results.merge(json)
|
|
146
146
|
end
|
|
147
147
|
end
|
|
@@ -189,10 +189,10 @@ class Terradoc
|
|
|
189
189
|
@raw_results['variable'].each do |key, value|
|
|
190
190
|
name = key.gsub('_', '\_')
|
|
191
191
|
default = value['default'].to_s.gsub('_', '\_')
|
|
192
|
-
required = if
|
|
193
|
-
'No'
|
|
194
|
-
else
|
|
192
|
+
required = if default.empty?
|
|
195
193
|
'Yes'
|
|
194
|
+
else
|
|
195
|
+
'No'
|
|
196
196
|
end
|
|
197
197
|
@config['variables']['raw_results'] << { :name => name, :description => value['description'], :type => value['type'], :default => default, :required => required }
|
|
198
198
|
end
|
data/lib/terradoc/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: terradoc
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.6
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Tim Gurney aka Wolf
|
|
@@ -102,6 +102,7 @@ files:
|
|
|
102
102
|
- LICENSE.md
|
|
103
103
|
- README.md
|
|
104
104
|
- Rakefile
|
|
105
|
+
- TEST
|
|
105
106
|
- VERSION.txt
|
|
106
107
|
- bin/console
|
|
107
108
|
- bin/setup
|