pdk 1.14.1 → 1.18.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (128) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +155 -2
  3. data/lib/pdk.rb +28 -19
  4. data/lib/pdk/answer_file.rb +2 -95
  5. data/lib/pdk/bolt.rb +19 -0
  6. data/lib/pdk/cli.rb +4 -5
  7. data/lib/pdk/cli/bundle.rb +5 -1
  8. data/lib/pdk/cli/config.rb +3 -1
  9. data/lib/pdk/cli/config/get.rb +3 -1
  10. data/lib/pdk/cli/console.rb +1 -1
  11. data/lib/pdk/cli/convert.rb +16 -10
  12. data/lib/pdk/cli/exec.rb +2 -1
  13. data/lib/pdk/cli/exec/command.rb +45 -4
  14. data/lib/pdk/cli/exec_group.rb +78 -43
  15. data/lib/pdk/cli/get.rb +20 -0
  16. data/lib/pdk/cli/get/config.rb +24 -0
  17. data/lib/pdk/cli/module/build.rb +1 -1
  18. data/lib/pdk/cli/module/generate.rb +1 -1
  19. data/lib/pdk/cli/new/class.rb +2 -2
  20. data/lib/pdk/cli/new/defined_type.rb +2 -2
  21. data/lib/pdk/cli/new/provider.rb +2 -2
  22. data/lib/pdk/cli/new/task.rb +2 -2
  23. data/lib/pdk/cli/new/test.rb +2 -2
  24. data/lib/pdk/cli/new/transport.rb +2 -2
  25. data/lib/pdk/cli/release.rb +192 -0
  26. data/lib/pdk/cli/release/prep.rb +39 -0
  27. data/lib/pdk/cli/release/publish.rb +40 -0
  28. data/lib/pdk/cli/remove.rb +20 -0
  29. data/lib/pdk/cli/remove/config.rb +80 -0
  30. data/lib/pdk/cli/set.rb +20 -0
  31. data/lib/pdk/cli/set/config.rb +119 -0
  32. data/lib/pdk/cli/update.rb +18 -8
  33. data/lib/pdk/cli/util.rb +7 -3
  34. data/lib/pdk/cli/util/update_manager_printer.rb +82 -0
  35. data/lib/pdk/cli/validate.rb +26 -44
  36. data/lib/pdk/config.rb +265 -8
  37. data/lib/pdk/config/ini_file.rb +183 -0
  38. data/lib/pdk/config/ini_file_setting.rb +39 -0
  39. data/lib/pdk/config/namespace.rb +26 -6
  40. data/lib/pdk/config/setting.rb +3 -2
  41. data/lib/pdk/context.rb +99 -0
  42. data/lib/pdk/context/control_repo.rb +60 -0
  43. data/lib/pdk/context/module.rb +28 -0
  44. data/lib/pdk/context/none.rb +22 -0
  45. data/lib/pdk/control_repo.rb +90 -0
  46. data/lib/pdk/generate.rb +1 -0
  47. data/lib/pdk/generate/defined_type.rb +25 -32
  48. data/lib/pdk/generate/module.rb +42 -35
  49. data/lib/pdk/generate/provider.rb +16 -65
  50. data/lib/pdk/generate/puppet_class.rb +25 -31
  51. data/lib/pdk/generate/puppet_object.rb +84 -189
  52. data/lib/pdk/generate/resource_api_object.rb +55 -0
  53. data/lib/pdk/generate/task.rb +28 -46
  54. data/lib/pdk/generate/transport.rb +21 -75
  55. data/lib/pdk/module.rb +1 -1
  56. data/lib/pdk/module/build.rb +38 -25
  57. data/lib/pdk/module/convert.rb +61 -42
  58. data/lib/pdk/module/metadata.rb +1 -3
  59. data/lib/pdk/module/release.rb +254 -0
  60. data/lib/pdk/module/update.rb +24 -16
  61. data/lib/pdk/module/update_manager.rb +8 -1
  62. data/lib/pdk/report.rb +18 -12
  63. data/lib/pdk/report/event.rb +6 -3
  64. data/lib/pdk/template.rb +59 -0
  65. data/lib/pdk/template/fetcher.rb +98 -0
  66. data/lib/pdk/template/fetcher/git.rb +85 -0
  67. data/lib/pdk/template/fetcher/local.rb +28 -0
  68. data/lib/pdk/template/renderer.rb +96 -0
  69. data/lib/pdk/template/renderer/v1.rb +25 -0
  70. data/lib/pdk/template/renderer/v1/legacy_template_dir.rb +116 -0
  71. data/lib/pdk/template/renderer/v1/renderer.rb +132 -0
  72. data/lib/pdk/template/renderer/v1/template_file.rb +102 -0
  73. data/lib/pdk/template/template_dir.rb +67 -0
  74. data/lib/pdk/tests/unit.rb +5 -0
  75. data/lib/pdk/util.rb +55 -45
  76. data/lib/pdk/util/bundler.rb +9 -9
  77. data/lib/pdk/util/changelog_generator.rb +120 -0
  78. data/lib/pdk/util/env.rb +28 -11
  79. data/lib/pdk/util/filesystem.rb +62 -2
  80. data/lib/pdk/util/git.rb +60 -8
  81. data/lib/pdk/util/json_finder.rb +84 -0
  82. data/lib/pdk/util/puppet_strings.rb +3 -3
  83. data/lib/pdk/util/puppet_version.rb +4 -5
  84. data/lib/pdk/util/ruby_version.rb +9 -6
  85. data/lib/pdk/util/template_uri.rb +60 -48
  86. data/lib/pdk/util/version.rb +4 -4
  87. data/lib/pdk/validate.rb +79 -25
  88. data/lib/pdk/validate/control_repo/control_repo_validator_group.rb +23 -0
  89. data/lib/pdk/validate/control_repo/environment_conf_validator.rb +98 -0
  90. data/lib/pdk/validate/external_command_validator.rb +208 -0
  91. data/lib/pdk/validate/internal_ruby_validator.rb +100 -0
  92. data/lib/pdk/validate/invokable_validator.rb +215 -0
  93. data/lib/pdk/validate/metadata/metadata_json_lint_validator.rb +86 -0
  94. data/lib/pdk/validate/metadata/metadata_syntax_validator.rb +78 -0
  95. data/lib/pdk/validate/metadata/metadata_validator_group.rb +20 -0
  96. data/lib/pdk/validate/puppet/puppet_epp_validator.rb +133 -0
  97. data/lib/pdk/validate/puppet/puppet_lint_validator.rb +66 -0
  98. data/lib/pdk/validate/puppet/puppet_syntax_validator.rb +137 -0
  99. data/lib/pdk/validate/puppet/puppet_validator_group.rb +21 -0
  100. data/lib/pdk/validate/ruby/ruby_rubocop_validator.rb +80 -0
  101. data/lib/pdk/validate/ruby/ruby_validator_group.rb +19 -0
  102. data/lib/pdk/validate/tasks/tasks_metadata_lint_validator.rb +88 -0
  103. data/lib/pdk/validate/tasks/tasks_name_validator.rb +50 -0
  104. data/lib/pdk/validate/tasks/tasks_validator_group.rb +20 -0
  105. data/lib/pdk/validate/validator.rb +118 -0
  106. data/lib/pdk/validate/validator_group.rb +104 -0
  107. data/lib/pdk/validate/yaml/yaml_syntax_validator.rb +95 -0
  108. data/lib/pdk/validate/yaml/yaml_validator_group.rb +19 -0
  109. data/lib/pdk/version.rb +1 -1
  110. data/locales/pdk.pot +755 -319
  111. metadata +66 -24
  112. data/lib/pdk/module/templatedir.rb +0 -391
  113. data/lib/pdk/template_file.rb +0 -96
  114. data/lib/pdk/validate/base_validator.rb +0 -215
  115. data/lib/pdk/validate/metadata/metadata_json_lint.rb +0 -82
  116. data/lib/pdk/validate/metadata/metadata_syntax.rb +0 -111
  117. data/lib/pdk/validate/metadata_validator.rb +0 -26
  118. data/lib/pdk/validate/puppet/puppet_epp.rb +0 -137
  119. data/lib/pdk/validate/puppet/puppet_lint.rb +0 -64
  120. data/lib/pdk/validate/puppet/puppet_syntax.rb +0 -137
  121. data/lib/pdk/validate/puppet_validator.rb +0 -26
  122. data/lib/pdk/validate/ruby/rubocop.rb +0 -72
  123. data/lib/pdk/validate/ruby_validator.rb +0 -26
  124. data/lib/pdk/validate/tasks/metadata_lint.rb +0 -130
  125. data/lib/pdk/validate/tasks/name.rb +0 -90
  126. data/lib/pdk/validate/tasks_validator.rb +0 -29
  127. data/lib/pdk/validate/yaml/syntax.rb +0 -125
  128. data/lib/pdk/validate/yaml_validator.rb +0 -28
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fa7118858cde5b6a4ea492a22683a8a077386d31e00157469186a373f91d8559
4
- data.tar.gz: 4feab9cf89fd58a0c4023d04905efaccb56021dc7f44d0110b332de0fd1c7781
3
+ metadata.gz: 7096c03ba45a582325f9d2d466da61571697d474ae04387511d18579e886ee65
4
+ data.tar.gz: 3df00dfaec659bcd94bf66970feb400990be1b84327ec9fbfd76ea0c0ddbff0b
5
5
  SHA512:
6
- metadata.gz: 63e8e385a5f17a12dd36d3d6938ee601e0020b0e8b55603ec409d111cd0add4f5b748c1cc493b7612d02381d1832d56ab7de7c933ab85c9773eee463e9c60dc9
7
- data.tar.gz: 33063bc92b0d8678cf2ac33333e23a1c3ca2d51bfece32eb326376f8681334e8b9574cf9a9df9c19da931248afc88197c0367e4659a81df9b96fca3ab6ba74fa
6
+ metadata.gz: ec2e4ee1a30f249b481c3282eecf5af1f6bfbe8497afde98b3f2c271beac0ab0b0d92ab78129e4cf564a7b48368f3cadfd9800d1cb5fb66b36816d93dea84882
7
+ data.tar.gz: 396091be92ce00e9b5816171e0782276e53de8b513ce9e50f14a1fe7b264042f2d4149182ba37cd7b7adaef7bb941ae395ffe703c721bd05f1fbdf778dd1f841
@@ -4,7 +4,125 @@ All changes to this repo will be documented in this file.
4
4
  See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) for a high-level summary.
5
5
 
6
6
 
7
+ ## [v1.18.1](https://github.com/puppetlabs/pdk/tree/v1.18.1) (2020-07-16)
8
+
9
+ [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.18.0...v1.18.1)
10
+
11
+ **Fixed bugs:**
12
+
13
+ - Don't attempt to modify a frozen string when parsing '--tests' paths [\#891](https://github.com/puppetlabs/pdk/pull/891) ([natemccurdy](https://github.com/natemccurdy))
14
+ - \(PDK-1653\) Ensure template have access to metadata during update/convert [\#883](https://github.com/puppetlabs/pdk/pull/883) ([scotje](https://github.com/scotje))
15
+
16
+ ## [v1.18.0](https://github.com/puppetlabs/pdk/tree/v1.18.0) (2020-05-12)
17
+
18
+ [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.17.0...v1.18.0)
19
+
20
+ **Implemented enhancements:**
21
+
22
+ - \(PDK-1109\) Add pdk remove config [\#870](https://github.com/puppetlabs/pdk/pull/870) ([glennsarti](https://github.com/glennsarti))
23
+ - \(PDK-1632\) Only show validators that are available in the given PDK Context [\#867](https://github.com/puppetlabs/pdk/pull/867) ([glennsarti](https://github.com/glennsarti))
24
+ - \(PDK-1615\) Add validator for environment.conf [\#866](https://github.com/puppetlabs/pdk/pull/866) ([glennsarti](https://github.com/glennsarti))
25
+ - \(PDK-1108\) Add pdk set config command [\#859](https://github.com/puppetlabs/pdk/pull/859) ([glennsarti](https://github.com/glennsarti))
26
+
27
+ **Fixed bugs:**
28
+
29
+ - Warning from libhoney when running unit test with PDK 1.17 [\#875](https://github.com/puppetlabs/pdk/issues/875)
30
+ - 'pdk convert' of a module that's inside a control repo adds boilerplate to the control repo [\#874](https://github.com/puppetlabs/pdk/issues/874)
31
+ - GemNotFound error for public\_suffix-3.1.1 when using --add-tests [\#869](https://github.com/puppetlabs/pdk/issues/869)
32
+ - Scrollback of failed rspec tests in VS code is extremely limited [\#829](https://github.com/puppetlabs/pdk/issues/829)
33
+ - Running individual rspec tests on Windows requires escaping the path [\#828](https://github.com/puppetlabs/pdk/issues/828)
34
+ - Generated descriptions for certain test comparisons break JUnit output [\#821](https://github.com/puppetlabs/pdk/issues/821)
35
+ - Fix PDK release command module validation [\#880](https://github.com/puppetlabs/pdk/pull/880) ([carabasdaniel](https://github.com/carabasdaniel))
36
+ - \(GH-828\) Munge backslash in rake paths for unit tests [\#878](https://github.com/puppetlabs/pdk/pull/878) ([glennsarti](https://github.com/glennsarti))
37
+ - \(GH-874\) Use PDK Context root for PDK Convert and Update [\#877](https://github.com/puppetlabs/pdk/pull/877) ([glennsarti](https://github.com/glennsarti))
38
+ - \(\#869\) Ensure bundle update on convert/update [\#871](https://github.com/puppetlabs/pdk/pull/871) ([rodjek](https://github.com/rodjek))
39
+ - \(\#821\) Allow for unbalanced JSON fragments in RSpec output [\#822](https://github.com/puppetlabs/pdk/pull/822) ([scotje](https://github.com/scotje))
40
+
41
+ **Merged pull requests:**
42
+
43
+ - \(MAINT\) Bump nokogiri and rake for security advisories [\#865](https://github.com/puppetlabs/pdk/pull/865) ([scotje](https://github.com/scotje))
44
+ - \(FIXUP\) Make system config path absolute instead of relative on POSIX hosts [\#862](https://github.com/puppetlabs/pdk/pull/862) ([scotje](https://github.com/scotje))
45
+
46
+ ## [v1.17.0](https://github.com/puppetlabs/pdk/tree/v1.17.0) (2020-02-27)
47
+
48
+ [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.16.0...v1.17.0)
49
+
50
+ **Implemented enhancements:**
51
+
52
+ - \(PDK-1618\)\(PDK-1613\)\(PDK-1616\) Add Control Repo support to Validators [\#858](https://github.com/puppetlabs/pdk/pull/858) ([glennsarti](https://github.com/glennsarti))
53
+ - \(PDK-1614\) Add project.environment settings [\#857](https://github.com/puppetlabs/pdk/pull/857) ([glennsarti](https://github.com/glennsarti))
54
+ - \(PDK-1615\) Add Ini File configuration support [\#856](https://github.com/puppetlabs/pdk/pull/856) ([glennsarti](https://github.com/glennsarti))
55
+ - \(PDK-1612\) Add PDK::Context and context detection [\#853](https://github.com/puppetlabs/pdk/pull/853) ([glennsarti](https://github.com/glennsarti))
56
+ - \(PDK-1607\)\(PDK-1608\) Implement system-level settings for PDK configuration [\#841](https://github.com/puppetlabs/pdk/pull/841) ([glennsarti](https://github.com/glennsarti))
57
+
58
+ **Fixed bugs:**
59
+
60
+ - Unable to automatically generate the changelog [\#855](https://github.com/puppetlabs/pdk/issues/855)
61
+ - 'pdk new module' bundler error with PDK-1.16 on macOS 10.14 [\#845](https://github.com/puppetlabs/pdk/issues/845)
62
+
63
+ **Merged pull requests:**
64
+
65
+ - \(\#855\) Use correct namespace for external Bundler call [\#860](https://github.com/puppetlabs/pdk/pull/860) ([rodjek](https://github.com/rodjek))
66
+ - \(maint\) Use Ruby 2.5 on Travis for PDK as a library tests [\#849](https://github.com/puppetlabs/pdk/pull/849) ([glennsarti](https://github.com/glennsarti))
67
+ - \(maint\) Update for Ruby 2.3 and JSON Schema tests [\#847](https://github.com/puppetlabs/pdk/pull/847) ([glennsarti](https://github.com/glennsarti))
68
+ - \(maint\) Add basic tests for running PDK unprivileged [\#846](https://github.com/puppetlabs/pdk/pull/846) ([rodjek](https://github.com/rodjek))
69
+ - \(PDK-1592\) Refactor PDK validators to be more singular purpose [\#831](https://github.com/puppetlabs/pdk/pull/831) ([glennsarti](https://github.com/glennsarti))
70
+
71
+ ## [v1.16.0](https://github.com/puppetlabs/pdk/tree/v1.16.0) (2020-02-05)
72
+
73
+ [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.15.0...v1.16.0)
74
+
75
+ **Implemented enhancements:**
76
+
77
+ - \(PDK-1545\) Include template-ref in module generation output [\#840](https://github.com/puppetlabs/pdk/pull/840) ([rodjek](https://github.com/rodjek))
78
+ - \(PDK-1587\) Reject paths with non-ASCII characters when building [\#832](https://github.com/puppetlabs/pdk/pull/832) ([rodjek](https://github.com/rodjek))
79
+ - \(PDK-1588\) Increase granularity of `pdk bundle` analytics [\#827](https://github.com/puppetlabs/pdk/pull/827) ([rodjek](https://github.com/rodjek))
80
+ - \(PDK-1557\) Detect Control Repositories [\#826](https://github.com/puppetlabs/pdk/pull/826) ([glennsarti](https://github.com/glennsarti))
81
+ - \(PDK-1556\) Use the module root when generating objects [\#824](https://github.com/puppetlabs/pdk/pull/824) ([glennsarti](https://github.com/glennsarti))
82
+
83
+ **Fixed bugs:**
84
+
85
+ - Puppetfile Resolver can't detect version of Puppet from PDK using Visual Studio Code [\#830](https://github.com/puppetlabs/pdk/issues/830)
86
+ - Validate and Test failing on new module [\#811](https://github.com/puppetlabs/pdk/issues/811)
87
+
88
+ **Merged pull requests:**
89
+
90
+ - \(maint\) Fix license\_finder failures [\#837](https://github.com/puppetlabs/pdk/pull/837) ([glennsarti](https://github.com/glennsarti))
91
+ - \(PDK-1590\) Remove Gemfile.lock before running bundle update [\#834](https://github.com/puppetlabs/pdk/pull/834) ([rodjek](https://github.com/rodjek))
92
+ - \(maint\) Use case insensitive environment variable names on Windows [\#825](https://github.com/puppetlabs/pdk/pull/825) ([glennsarti](https://github.com/glennsarti))
93
+ - \(maint\) Update methods for Bundler 2.x deprecations [\#820](https://github.com/puppetlabs/pdk/pull/820) ([glennsarti](https://github.com/glennsarti))
94
+ - \(MAINT\) Refactor how gem\_path to bundler is calculated [\#745](https://github.com/puppetlabs/pdk/pull/745) ([scotje](https://github.com/scotje))
95
+
96
+ ## [v1.15.0](https://github.com/puppetlabs/pdk/tree/v1.15.0) (2019-12-13)
97
+
98
+ [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.14.1...v1.15.0)
99
+
100
+ **Implemented enhancements:**
101
+
102
+ - \(PDK-1488\) Inform user if updating a pinned module [\#816](https://github.com/puppetlabs/pdk/pull/816) ([rodjek](https://github.com/rodjek))
103
+ - \(PDK-1487\) Add --default-template flag to pdk convert [\#814](https://github.com/puppetlabs/pdk/pull/814) ([rodjek](https://github.com/rodjek))
104
+ - \(GH-808\) Implement pdk release prep and publish subcommands [\#813](https://github.com/puppetlabs/pdk/pull/813) ([glennsarti](https://github.com/glennsarti))
105
+ - \(GH-808\) Implement pdk release subcommand [\#809](https://github.com/puppetlabs/pdk/pull/809) ([glennsarti](https://github.com/glennsarti))
106
+ - \(PDK-1364\) Allow non-git template directories to be used [\#803](https://github.com/puppetlabs/pdk/pull/803) ([glennsarti](https://github.com/glennsarti))
107
+
108
+ **Fixed bugs:**
109
+
110
+ - \(UI\) Remove UTF-8 "smart quotes" from PDK output [\#806](https://github.com/puppetlabs/pdk/issues/806)
111
+ - \(GH-808\) Fix prompt for pdk release [\#812](https://github.com/puppetlabs/pdk/pull/812) ([glennsarti](https://github.com/glennsarti))
112
+ - \(PDK-1169\) Add VMWare fallback to PDK::Util::Filesystem.mv [\#802](https://github.com/puppetlabs/pdk/pull/802) ([rodjek](https://github.com/rodjek))
113
+
114
+ **Closed issues:**
115
+
116
+ - Implement `pdk release` command as per RFC \(part 1\) [\#808](https://github.com/puppetlabs/pdk/issues/808)
117
+ - Cannot install pdk 1.14.1.0-1xenial deb - Operation not permitted [\#798](https://github.com/puppetlabs/pdk/issues/798)
118
+
119
+ **Merged pull requests:**
120
+
121
+ - \(\#806\) Use ASCII quotes instead of Unicode quotes [\#807](https://github.com/puppetlabs/pdk/pull/807) ([rodjek](https://github.com/rodjek))
122
+ - \(PDK-1523\) Refactor filesystem operations to use PDK::Util::Filesystem [\#799](https://github.com/puppetlabs/pdk/pull/799) ([rodjek](https://github.com/rodjek))
123
+
7
124
  ## [v1.14.1](https://github.com/puppetlabs/pdk/tree/v1.14.1) (2019-11-01)
125
+
8
126
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.14.0...v1.14.1)
9
127
 
10
128
  **Fixed bugs:**
@@ -36,6 +154,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
36
154
  - \(\#770\) Add missing require to PDK::Module::Metadata.from\_file [\#771](https://github.com/puppetlabs/pdk/pull/771) ([hajee](https://github.com/hajee))
37
155
 
38
156
  ## [v1.14.0](https://github.com/puppetlabs/pdk/tree/v1.14.0) (2019-10-09)
157
+
39
158
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.13.0...v1.14.0)
40
159
 
41
160
  **Implemented enhancements:**
@@ -61,6 +180,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
61
180
  - \(MAINT\) Bump version to 1.14.0.pre [\#741](https://github.com/puppetlabs/pdk/pull/741) ([scotje](https://github.com/scotje))
62
181
 
63
182
  ## [v1.13.0](https://github.com/puppetlabs/pdk/tree/v1.13.0) (2019-08-29)
183
+
64
184
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.12.0...v1.13.0)
65
185
 
66
186
  **Implemented enhancements:**
@@ -78,7 +198,6 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
78
198
  - Windows MSI installer fails with PDK 1.12.0 [\#721](https://github.com/puppetlabs/pdk/issues/721)
79
199
  - Handle deleted template files for new module [\#725](https://github.com/puppetlabs/pdk/pull/725) ([seanmil](https://github.com/seanmil))
80
200
  - \(GH-722\) Do not emit nil targets for validators against a directory [\#724](https://github.com/puppetlabs/pdk/pull/724) ([glennsarti](https://github.com/glennsarti))
81
- - \(maint\) avoid interfering with local ruby configs [\#86](https://github.com/puppetlabs/pdk/pull/86) ([DavidS](https://github.com/DavidS))
82
201
 
83
202
  **Merged pull requests:**
84
203
 
@@ -94,6 +213,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
94
213
  - \(PDK-1432\) Autogenerate PowerShell modules from code [\#701](https://github.com/puppetlabs/pdk/pull/701) ([glennsarti](https://github.com/glennsarti))
95
214
 
96
215
  ## [v1.12.0](https://github.com/puppetlabs/pdk/tree/v1.12.0) (2019-07-31)
216
+
97
217
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.11.1...v1.12.0)
98
218
 
99
219
  **Implemented enhancements:**
@@ -127,6 +247,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
127
247
  - \(PDK-1333\) command\_spec rake task [\#644](https://github.com/puppetlabs/pdk/pull/644) ([rodjek](https://github.com/rodjek))
128
248
 
129
249
  ## [v1.11.1](https://github.com/puppetlabs/pdk/tree/v1.11.1) (2019-07-01)
250
+
130
251
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.11.0...v1.11.1)
131
252
 
132
253
  **Closed issues:**
@@ -141,6 +262,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
141
262
  - \(PDK-1409\) Bump PDK version to 1.11.1.pre [\#688](https://github.com/puppetlabs/pdk/pull/688) ([rodjek](https://github.com/rodjek))
142
263
 
143
264
  ## [v1.11.0](https://github.com/puppetlabs/pdk/tree/v1.11.0) (2019-06-27)
265
+
144
266
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.10.0...v1.11.0)
145
267
 
146
268
  **Fixed bugs:**
@@ -190,6 +312,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
190
312
  - \(PDK-1193\) Saves packaged template-url in metadata as a keyword [\#639](https://github.com/puppetlabs/pdk/pull/639) ([bmjen](https://github.com/bmjen))
191
313
 
192
314
  ## [v1.10.0](https://github.com/puppetlabs/pdk/tree/v1.10.0) (2019-04-02)
315
+
193
316
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.9.1...v1.10.0)
194
317
 
195
318
  **Implemented enhancements:**
@@ -215,6 +338,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
215
338
  - \(PDK-1298\) acceptance:local test suite optimisation [\#633](https://github.com/puppetlabs/pdk/pull/633) ([rodjek](https://github.com/rodjek))
216
339
 
217
340
  ## [v1.9.1](https://github.com/puppetlabs/pdk/tree/v1.9.1) (2019-03-01)
341
+
218
342
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.9.0...v1.9.1)
219
343
 
220
344
  **Fixed bugs:**
@@ -232,6 +356,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
232
356
  - \(PDK-1260\) Bump to 1.10.0.pre for new dev work [\#621](https://github.com/puppetlabs/pdk/pull/621) ([bmjen](https://github.com/bmjen))
233
357
 
234
358
  ## [v1.9.0](https://github.com/puppetlabs/pdk/tree/v1.9.0) (2019-01-29)
359
+
235
360
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.8.0...v1.9.0)
236
361
 
237
362
  **Implemented enhancements:**
@@ -263,6 +388,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
263
388
  - \(PDK-1001\) Chdir before execing git rather than "git -C" [\#602](https://github.com/puppetlabs/pdk/pull/602) ([rodjek](https://github.com/rodjek))
264
389
 
265
390
  ## [v1.8.0](https://github.com/puppetlabs/pdk/tree/v1.8.0) (2018-11-28)
391
+
266
392
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.7.1...v1.8.0)
267
393
 
268
394
  **Implemented enhancements:**
@@ -300,6 +426,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
300
426
  - \(maint\) Bump version for dev [\#577](https://github.com/puppetlabs/pdk/pull/577) ([bmjen](https://github.com/bmjen))
301
427
 
302
428
  ## [v1.7.1](https://github.com/puppetlabs/pdk/tree/v1.7.1) (2018-10-05)
429
+
303
430
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.7.0...v1.7.1)
304
431
 
305
432
  **Implemented enhancements:**
@@ -321,6 +448,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
321
448
  - Bump version to 1.8.0.pre [\#564](https://github.com/puppetlabs/pdk/pull/564) ([bmjen](https://github.com/bmjen))
322
449
 
323
450
  ## [v1.7.0](https://github.com/puppetlabs/pdk/tree/v1.7.0) (2018-08-15)
451
+
324
452
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.6.1...v1.7.0)
325
453
 
326
454
  **Implemented enhancements:**
@@ -339,6 +467,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
339
467
  - \(PDK-1077\) Expand the package acceptance test suite [\#554](https://github.com/puppetlabs/pdk/pull/554) ([rodjek](https://github.com/rodjek))
340
468
 
341
469
  ## [v1.6.1](https://github.com/puppetlabs/pdk/tree/v1.6.1) (2018-07-25)
470
+
342
471
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.6.0...v1.6.1)
343
472
 
344
473
  **Implemented enhancements:**
@@ -377,6 +506,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
377
506
  - \(maint\) Bump version for next dev cycle [\#529](https://github.com/puppetlabs/pdk/pull/529) ([bmjen](https://github.com/bmjen))
378
507
 
379
508
  ## [v1.6.0](https://github.com/puppetlabs/pdk/tree/v1.6.0) (2018-06-21)
509
+
380
510
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.5.0...v1.6.0)
381
511
 
382
512
  **Implemented enhancements:**
@@ -415,6 +545,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
415
545
  - Convert package acceptance tests over to beaker-rspec & serverspec [\#495](https://github.com/puppetlabs/pdk/pull/495) ([rodjek](https://github.com/rodjek))
416
546
 
417
547
  ## [v1.5.0](https://github.com/puppetlabs/pdk/tree/v1.5.0) (2018-04-30)
548
+
418
549
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.4.1...v1.5.0)
419
550
 
420
551
  **Implemented enhancements:**
@@ -469,6 +600,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
469
600
  - \(maint\) Fixup remaining ruby 2.4.3 issues [\#454](https://github.com/puppetlabs/pdk/pull/454) ([bmjen](https://github.com/bmjen))
470
601
 
471
602
  ## [v1.4.1](https://github.com/puppetlabs/pdk/tree/v1.4.1) (2018-02-26)
603
+
472
604
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.4.0...v1.4.1)
473
605
 
474
606
  **Fixed bugs:**
@@ -488,6 +620,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
488
620
  - Release 1.4.1 [\#435](https://github.com/puppetlabs/pdk/pull/435) ([bmjen](https://github.com/bmjen))
489
621
 
490
622
  ## [v1.4.0](https://github.com/puppetlabs/pdk/tree/v1.4.0) (2018-02-21)
623
+
491
624
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.3.2...v1.4.0)
492
625
 
493
626
  **Implemented enhancements:**
@@ -531,6 +664,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
531
664
  - \(PDK-575\) Run puppet parser validate with an dummy empty puppet.conf [\#402](https://github.com/puppetlabs/pdk/pull/402) ([rodjek](https://github.com/rodjek))
532
665
 
533
666
  ## [v1.3.2](https://github.com/puppetlabs/pdk/tree/v1.3.2) (2018-01-17)
667
+
534
668
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.3.1...v1.3.2)
535
669
 
536
670
  **Closed issues:**
@@ -547,6 +681,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
547
681
  - \(PDK-739\) Fall back to default template if necessary [\#400](https://github.com/puppetlabs/pdk/pull/400) ([rodjek](https://github.com/rodjek))
548
682
 
549
683
  ## [v1.3.1](https://github.com/puppetlabs/pdk/tree/v1.3.1) (2017-12-20)
684
+
550
685
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.3.0...v1.3.1)
551
686
 
552
687
  **Fixed bugs:**
@@ -558,6 +693,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
558
693
  - Release Prep for 1.3.1 Hotfix [\#398](https://github.com/puppetlabs/pdk/pull/398) ([HelenCampbell](https://github.com/HelenCampbell))
559
694
 
560
695
  ## [v1.3.0](https://github.com/puppetlabs/pdk/tree/v1.3.0) (2017-12-15)
696
+
561
697
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.2.1...v1.3.0)
562
698
 
563
699
  **Implemented enhancements:**
@@ -619,6 +755,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
619
755
  - \(PDK-621\) Implement a skeleton `pdk convert` command [\#335](https://github.com/puppetlabs/pdk/pull/335) ([rodjek](https://github.com/rodjek))
620
756
 
621
757
  ## [v1.2.1](https://github.com/puppetlabs/pdk/tree/v1.2.1) (2017-10-26)
758
+
622
759
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.2.0...v1.2.1)
623
760
 
624
761
  **Fixed bugs:**
@@ -643,6 +780,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
643
780
  - Fix link to PDK docs [\#317](https://github.com/puppetlabs/pdk/pull/317) ([turbodog](https://github.com/turbodog))
644
781
 
645
782
  ## [v1.2.0](https://github.com/puppetlabs/pdk/tree/v1.2.0) (2017-10-06)
783
+
646
784
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.1.0...v1.2.0)
647
785
 
648
786
  **Implemented enhancements:**
@@ -673,6 +811,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
673
811
  - \(PDK-468\) Adding parameters field to task metadata [\#300](https://github.com/puppetlabs/pdk/pull/300) ([bmjen](https://github.com/bmjen))
674
812
 
675
813
  ## [v1.1.0](https://github.com/puppetlabs/pdk/tree/v1.1.0) (2017-09-13)
814
+
676
815
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.0.1...v1.1.0)
677
816
 
678
817
  **Implemented enhancements:**
@@ -717,6 +856,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
717
856
  - \(maint\) Updates version to 1.1.0.pre [\#264](https://github.com/puppetlabs/pdk/pull/264) ([bmjen](https://github.com/bmjen))
718
857
 
719
858
  ## [v1.0.1](https://github.com/puppetlabs/pdk/tree/v1.0.1) (2017-08-17)
859
+
720
860
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v1.0.0...v1.0.1)
721
861
 
722
862
  **Fixed bugs:**
@@ -731,6 +871,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
731
871
  - Formatting fix [\#258](https://github.com/puppetlabs/pdk/pull/258) ([turbodog](https://github.com/turbodog))
732
872
 
733
873
  ## [v1.0.0](https://github.com/puppetlabs/pdk/tree/v1.0.0) (2017-08-15)
874
+
734
875
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.6.0...v1.0.0)
735
876
 
736
877
  **Implemented enhancements:**
@@ -765,6 +906,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
765
906
  - \(maint\) add license auditing to travis [\#205](https://github.com/puppetlabs/pdk/pull/205) ([DavidS](https://github.com/DavidS))
766
907
 
767
908
  ## [v0.6.0](https://github.com/puppetlabs/pdk/tree/v0.6.0) (2017-08-08)
909
+
768
910
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.5.0...v0.6.0)
769
911
 
770
912
  **Implemented enhancements:**
@@ -828,6 +970,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
828
970
  - \(maint\) Move contributor's notes to separate file [\#181](https://github.com/puppetlabs/pdk/pull/181) ([DavidS](https://github.com/DavidS))
829
971
 
830
972
  ## [v0.5.0](https://github.com/puppetlabs/pdk/tree/v0.5.0) (2017-07-20)
973
+
831
974
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.4.4...v0.5.0)
832
975
 
833
976
  **Implemented enhancements:**
@@ -847,6 +990,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
847
990
  - \(maint\) Finish PDK::Validate::\* unit tests [\#139](https://github.com/puppetlabs/pdk/pull/139) ([rodjek](https://github.com/rodjek))
848
991
 
849
992
  ## [v0.4.4](https://github.com/puppetlabs/pdk/tree/v0.4.4) (2017-07-18)
993
+
850
994
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.4.3...v0.4.4)
851
995
 
852
996
  **Fixed bugs:**
@@ -868,6 +1012,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
868
1012
  - \(maint\) fix `new module` description in README [\#169](https://github.com/puppetlabs/pdk/pull/169) ([DavidS](https://github.com/DavidS))
869
1013
 
870
1014
  ## [v0.4.3](https://github.com/puppetlabs/pdk/tree/v0.4.3) (2017-07-17)
1015
+
871
1016
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.4.2...v0.4.3)
872
1017
 
873
1018
  **Fixed bugs:**
@@ -880,6 +1025,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
880
1025
  - \(MAINT\) Re-bump version to 0.5.0.pre [\#163](https://github.com/puppetlabs/pdk/pull/163) ([scotje](https://github.com/scotje))
881
1026
 
882
1027
  ## [v0.4.2](https://github.com/puppetlabs/pdk/tree/v0.4.2) (2017-07-17)
1028
+
883
1029
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.4.1...v0.4.2)
884
1030
 
885
1031
  **Fixed bugs:**
@@ -895,6 +1041,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
895
1041
  - \(maint\) Bumps version for next dev cycle. [\#152](https://github.com/puppetlabs/pdk/pull/152) ([bmjen](https://github.com/bmjen))
896
1042
 
897
1043
  ## [v0.4.1](https://github.com/puppetlabs/pdk/tree/v0.4.1) (2017-07-14)
1044
+
898
1045
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.4.0...v0.4.1)
899
1046
 
900
1047
  **Fixed bugs:**
@@ -906,6 +1053,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
906
1053
  - Release prep 0.4.1 [\#155](https://github.com/puppetlabs/pdk/pull/155) ([scotje](https://github.com/scotje))
907
1054
 
908
1055
  ## [v0.4.0](https://github.com/puppetlabs/pdk/tree/v0.4.0) (2017-07-14)
1056
+
909
1057
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.3.0...v0.4.0)
910
1058
 
911
1059
  **Implemented enhancements:**
@@ -941,6 +1089,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
941
1089
  - \(idea\) More expressive RSpec matchers for JUnit XML content [\#117](https://github.com/puppetlabs/pdk/pull/117) ([rodjek](https://github.com/rodjek))
942
1090
 
943
1091
  ## [v0.3.0](https://github.com/puppetlabs/pdk/tree/v0.3.0) (2017-06-29)
1092
+
944
1093
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.2.0...v0.3.0)
945
1094
 
946
1095
  **Implemented enhancements:**
@@ -978,6 +1127,7 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
978
1127
  - \(SDK-256\) Acceptance tests for metadata validator behavior and output [\#99](https://github.com/puppetlabs/pdk/pull/99) ([rodjek](https://github.com/rodjek))
979
1128
 
980
1129
  ## [v0.2.0](https://github.com/puppetlabs/pdk/tree/v0.2.0) (2017-06-21)
1130
+
981
1131
  [Full Changelog](https://github.com/puppetlabs/pdk/compare/v0.1.0...v0.2.0)
982
1132
 
983
1133
  **Implemented enhancements:**
@@ -1028,6 +1178,9 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
1028
1178
  - Relax data type validation to warn when non-standard types used [\#59](https://github.com/puppetlabs/pdk/pull/59) ([rodjek](https://github.com/rodjek))
1029
1179
 
1030
1180
  ## [v0.1.0](https://github.com/puppetlabs/pdk/tree/v0.1.0) (2017-06-05)
1181
+
1182
+ [Full Changelog](https://github.com/puppetlabs/pdk/compare/2be9329bed4715c888f273814b99f2cf37ee9341...v0.1.0)
1183
+
1031
1184
  **Implemented enhancements:**
1032
1185
 
1033
1186
  - \(maint\) update Contributing section [\#56](https://github.com/puppetlabs/pdk/pull/56) ([DavidS](https://github.com/DavidS))
@@ -1082,4 +1235,4 @@ See the [release notes](https://puppet.com/docs/pdk/latest/release_notes.html) f
1082
1235
 
1083
1236
 
1084
1237
 
1085
- \* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
1238
+ \* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*
data/lib/pdk.rb CHANGED
@@ -3,12 +3,15 @@ require 'pdk/i18n'
3
3
  module PDK
4
4
  autoload :Analytics, 'pdk/analytics'
5
5
  autoload :AnswerFile, 'pdk/answer_file'
6
+ autoload :Bolt, 'pdk/bolt'
6
7
  autoload :Config, 'pdk/config'
8
+ autoload :Context, 'pdk/context'
9
+ autoload :ControlRepo, 'pdk/control_repo'
7
10
  autoload :Generate, 'pdk/generate'
8
11
  autoload :Logger, 'pdk/logger'
9
12
  autoload :Module, 'pdk/module'
10
13
  autoload :Report, 'pdk/report'
11
- autoload :TemplateFile, 'pdk/template_file'
14
+ autoload :Template, 'pdk/template'
12
15
  autoload :TEMPLATE_REF, 'pdk/version'
13
16
  autoload :Util, 'pdk/util'
14
17
  autoload :Validate, 'pdk/validate'
@@ -28,35 +31,41 @@ module PDK
28
31
  autoload :Unit, 'pdk/tests/unit'
29
32
  end
30
33
 
31
- # Singleton accessor to the current answer file being used by the PDK.
32
- #
33
- # @return [PDK::AnswerFile] The AnswerFile instance currently being used by
34
- # the PDK.
35
- def self.answers
36
- @answer_file ||= PDK::AnswerFile.new
34
+ def self.logger
35
+ @logger ||= PDK::Logger.new
37
36
  end
38
37
 
39
- # Specify the path to a custom answer file that the PDK should use.
40
- #
41
- # @param path [String] A path on disk to the file where the PDK should store
42
- # answers to interactive questions.
43
- def self.answer_file=(path)
44
- @answer_file = PDK::AnswerFile.new(path)
38
+ def self.config
39
+ return @config unless @config.nil?
40
+ options = {}
41
+ options['user.module_defaults.path'] = PDK::Util::Env['PDK_ANSWER_FILE'] unless PDK::Util::Env['PDK_ANSWER_FILE'].nil?
42
+ @config = PDK::Config.new(options)
45
43
  end
46
44
 
47
- def self.logger
48
- @logger ||= PDK::Logger.new
45
+ def self.context
46
+ @context ||= PDK::Context.create(Dir.pwd)
49
47
  end
50
48
 
51
- def self.config
52
- @config ||= PDK::Config.new
49
+ def self.available_feature_flags
50
+ @available_feature_flags ||= %w[
51
+ controlrepo
52
+ ].freeze
53
+ end
54
+
55
+ def self.requested_feature_flags
56
+ @requested_feature_flags ||= (PDK::Util::Env['PDK_FEATURE_FLAGS'] || '').split(',').map { |flag| flag.strip }
57
+ end
58
+
59
+ def self.feature_flag?(flagname)
60
+ return false unless available_feature_flags.include?(flagname)
61
+ requested_feature_flags.include?(flagname)
53
62
  end
54
63
 
55
64
  def self.analytics
56
65
  @analytics ||= PDK::Analytics.build_client(
57
66
  logger: PDK.logger,
58
- disabled: PDK::Util::Env['PDK_DISABLE_ANALYTICS'] || PDK.config.user['analytics']['disabled'],
59
- user_id: PDK.config.user['analytics']['user-id'],
67
+ disabled: PDK::Util::Env['PDK_DISABLE_ANALYTICS'] || PDK.config.get_within_scopes('analytics.disabled', %w[user system]),
68
+ user_id: PDK.config.get_within_scopes('analytics.user-id', %w[user system]),
60
69
  app_id: "UA-139917834-#{PDK::Util.development_mode? ? '2' : '1'}",
61
70
  client: :google_analytics,
62
71
  app_name: 'pdk',