puppet-strings 1.1.1 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -0
  3. data/Gemfile +4 -2
  4. data/README.md +53 -10
  5. data/codecov.yml +3 -0
  6. data/lib/puppet-strings.rb +30 -11
  7. data/lib/puppet-strings/json.rb +7 -0
  8. data/lib/puppet-strings/markdown.rb +35 -0
  9. data/lib/puppet-strings/markdown/base.rb +168 -0
  10. data/lib/puppet-strings/markdown/defined_type.rb +14 -0
  11. data/lib/puppet-strings/markdown/defined_types.rb +37 -0
  12. data/lib/puppet-strings/markdown/function.rb +52 -0
  13. data/lib/puppet-strings/markdown/functions.rb +38 -0
  14. data/lib/puppet-strings/markdown/puppet_class.rb +14 -0
  15. data/lib/puppet-strings/markdown/puppet_classes.rb +37 -0
  16. data/lib/puppet-strings/markdown/resource_type.rb +27 -0
  17. data/lib/puppet-strings/markdown/resource_types.rb +37 -0
  18. data/lib/puppet-strings/markdown/table_of_contents.rb +21 -0
  19. data/lib/puppet-strings/markdown/templates/classes_and_defines.erb +63 -0
  20. data/lib/puppet-strings/markdown/templates/function.erb +50 -0
  21. data/lib/puppet-strings/markdown/templates/resource_type.erb +114 -0
  22. data/lib/puppet-strings/markdown/templates/table_of_contents.erb +21 -0
  23. data/lib/puppet-strings/tasks/generate.rb +24 -5
  24. data/lib/puppet-strings/yard/code_objects/function.rb +3 -3
  25. data/lib/puppet-strings/yard/code_objects/type.rb +3 -1
  26. data/lib/puppet-strings/yard/handlers.rb +1 -0
  27. data/lib/puppet-strings/yard/handlers/puppet/function_handler.rb +1 -1
  28. data/lib/puppet-strings/yard/handlers/ruby/base.rb +1 -1
  29. data/lib/puppet-strings/yard/handlers/ruby/rsapi_handler.rb +141 -0
  30. data/lib/puppet/face/strings.rb +28 -7
  31. data/spec/acceptance/emit_json_options.rb +4 -4
  32. data/spec/acceptance/generate_markdown_spec.rb +49 -0
  33. data/spec/fixtures/unit/json/output.json +43 -0
  34. data/spec/fixtures/unit/markdown/output.md +383 -0
  35. data/spec/spec_helper.rb +19 -1
  36. data/spec/unit/puppet-strings/json_spec.rb +40 -0
  37. data/spec/unit/puppet-strings/markdown/base_spec.rb +146 -0
  38. data/spec/unit/puppet-strings/markdown_spec.rb +248 -0
  39. data/spec/unit/puppet-strings/yard/handlers/puppet/function_handler_spec.rb +16 -1
  40. data/spec/unit/puppet-strings/yard/handlers/ruby/provider_handler_spec.rb +1 -1
  41. data/spec/unit/puppet-strings/yard/handlers/ruby/rsapi_handler_spec.rb +213 -0
  42. metadata +38 -2
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppet-strings
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Puppet Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-10-20 00:00:00.000000000 Z
11
+ date: 2018-02-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: yard
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: 0.9.5
27
+ - !ruby/object:Gem::Dependency
28
+ name: rgen
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
27
41
  description: Puppet documentation via YARD
28
42
  email: info@puppet.com
29
43
  executables: []
@@ -44,8 +58,24 @@ files:
44
58
  - MAINTAINERS
45
59
  - README.md
46
60
  - Rakefile
61
+ - codecov.yml
47
62
  - lib/puppet-strings.rb
48
63
  - lib/puppet-strings/json.rb
64
+ - lib/puppet-strings/markdown.rb
65
+ - lib/puppet-strings/markdown/base.rb
66
+ - lib/puppet-strings/markdown/defined_type.rb
67
+ - lib/puppet-strings/markdown/defined_types.rb
68
+ - lib/puppet-strings/markdown/function.rb
69
+ - lib/puppet-strings/markdown/functions.rb
70
+ - lib/puppet-strings/markdown/puppet_class.rb
71
+ - lib/puppet-strings/markdown/puppet_classes.rb
72
+ - lib/puppet-strings/markdown/resource_type.rb
73
+ - lib/puppet-strings/markdown/resource_types.rb
74
+ - lib/puppet-strings/markdown/table_of_contents.rb
75
+ - lib/puppet-strings/markdown/templates/classes_and_defines.erb
76
+ - lib/puppet-strings/markdown/templates/function.erb
77
+ - lib/puppet-strings/markdown/templates/resource_type.erb
78
+ - lib/puppet-strings/markdown/templates/table_of_contents.erb
49
79
  - lib/puppet-strings/tasks.rb
50
80
  - lib/puppet-strings/tasks/generate.rb
51
81
  - lib/puppet-strings/tasks/gh_pages.rb
@@ -67,6 +97,7 @@ files:
67
97
  - lib/puppet-strings/yard/handlers/ruby/base.rb
68
98
  - lib/puppet-strings/yard/handlers/ruby/function_handler.rb
69
99
  - lib/puppet-strings/yard/handlers/ruby/provider_handler.rb
100
+ - lib/puppet-strings/yard/handlers/ruby/rsapi_handler.rb
70
101
  - lib/puppet-strings/yard/handlers/ruby/type_handler.rb
71
102
  - lib/puppet-strings/yard/parsers.rb
72
103
  - lib/puppet-strings/yard/parsers/puppet/parser.rb
@@ -126,6 +157,7 @@ files:
126
157
  - lib/puppet/feature/rgen.rb
127
158
  - lib/puppet/feature/yard.rb
128
159
  - spec/acceptance/emit_json_options.rb
160
+ - spec/acceptance/generate_markdown_spec.rb
129
161
  - spec/acceptance/lib/util.rb
130
162
  - spec/acceptance/running_strings_generate.rb
131
163
  - spec/fixtures/acceptance/modules/test/functions/add.pp
@@ -138,14 +170,18 @@ files:
138
170
  - spec/fixtures/acceptance/modules/test/metadata.json
139
171
  - spec/fixtures/unit/json/output.json
140
172
  - spec/fixtures/unit/json/output_without_puppet_function.json
173
+ - spec/fixtures/unit/markdown/output.md
141
174
  - spec/spec_helper.rb
142
175
  - spec/spec_helper_acceptance.rb
143
176
  - spec/unit/puppet-strings/json_spec.rb
177
+ - spec/unit/puppet-strings/markdown/base_spec.rb
178
+ - spec/unit/puppet-strings/markdown_spec.rb
144
179
  - spec/unit/puppet-strings/yard/handlers/puppet/class_handler_spec.rb
145
180
  - spec/unit/puppet-strings/yard/handlers/puppet/defined_type_handler_spec.rb
146
181
  - spec/unit/puppet-strings/yard/handlers/puppet/function_handler_spec.rb
147
182
  - spec/unit/puppet-strings/yard/handlers/ruby/function_handler_spec.rb
148
183
  - spec/unit/puppet-strings/yard/handlers/ruby/provider_handler_spec.rb
184
+ - spec/unit/puppet-strings/yard/handlers/ruby/rsapi_handler_spec.rb
149
185
  - spec/unit/puppet-strings/yard/handlers/ruby/type_handler_spec.rb
150
186
  - spec/unit/puppet-strings/yard/parsers/puppet/parser_spec.rb
151
187
  - spec/unit/puppet-strings/yard/util_spec.rb