This patch moves from using a matrix of ruby and puppet version and then
excluding the incompatibilities to including supported versions. This
makes it much easier to see what is supported while also ensuring the
correct matrix of tests.
https://docs.puppet.com/puppet/4.10/about_agent.html
In the rake task strings::generate, the arguments json and yard_args
are not applied properly. The logic uses args.key?, however args is not
a Hash but a Rake::TaskArguments (and Enumerable). There is now key?
method.
Use Rake::TaskArguments.has_key? instead.
Prevent mass-changes to files by removing the date in the footer of each page.
Since the generation date isn't particularly useful and isn't tied to either
a git revision or a released version, this could be an easy way to address this
bug. The files will of-course be regenerated but if there are no changes then
the content will be identical and git will not notice.
* install the correct CAs in the correct places so windows can install gems
* use a gem_command abstraction to find the correct puppet gem exe
[skip ci]
* windows install requires type=aio so gem_command can find the right gem exe
* this change also allows easier command line use
* by using a sensible default for the acceptance key
[skip ci]
Because Puppet 4 is typed, parameter type information can
be automatically determined without any explicit documentation
in @param tags. However, users may desire to do so anyway for
consistency. This commit allows @param tags to include a [type]
in Puppet 4 code. Strings will emit a warning if the documented
type does not match the actual type. In such an event, the incorrect
documented type will be ignored in favor of the real one.
There is currently a parsing bug in YAD 0.9.6 and above
which causes errors on certain strings with '/' characters.
We'll pin to YARD 0.9.5 until the issue is resolved on YARD's
side.
See https://github.com/lsegal/yard/issues/1054.
This commit adds a new top-level key to the JSON schema for Ruby 3x/4x
puppet functions: `signatures`. This key is an array and is constructed entirely
with data from existing elements of the puppet function object. The data
structure itself remains unchanged, as this commit only affects the final
JSON output for functions.
In the case of a puppet 4x function with multiple dispatches (overloads),
the signatures key is populated with the equivalent of an overload tag
for each which includes the signature and any param or return tags for
the dispatch.
In the case of a puppet function with only one dispatch, the array is
simply populated with a single element containing a lone dispatch
and its param and return tags.
Note that this change does not affect the internal structure or
representation of puppet function objects, but rather only affects
its final display form when serialized into JSON. All prior data
has been left intact, and the only change here is the addition
of the `signatures` member to the JSON output.
Previously, overload objects were not displaying their tags when
they had no docstring text. This was due to an issue in the overload
`to_hash` method, which prevented the tags from being serialized when
the dispatch had no top-level text. This commit updates that logic
so that the tags will always be included in the hash if they exist.
Previously, Strings ignored calls to `return_type` in Puppet 4.x API
function dispatches, preventing the return types of overloads from
being automatically determined. This commit adds a check for a node
with a `return_type` call and handles it properly.