Age | Commit message (Collapse) | Author |
|
(MODULES-2561) add is_a function
|
|
[MODULES-2462] Improve parseyaml function
|
|
The data type system is very hard to understand. Many people don't
understand why
type_of([1,2,3]) == Array
will fail, but
type_of([1,2,3]) <= Array
passes. This does a simpler validation that doesn't rely on explicit
data types. Instead, use
$foo = [1,2,3]
if $foo.is_a(Array) {
notify { 'This is an array': }
}
This is based on code by Ben Ford <ben.ford@puppetlabs.com>.
* Added acceptance tests
* Added dispatch
* Improved unit tests
* Added docs to README
|
|
accept any case of boolean strings
|
|
[MAINT] Improve 'try_get_value' readme
|
|
|
|
* previously the str2bool function did not accept 'TRUE' as a bool
type. This causes the function to now accept TRUE, FALSE strings
as a boolean type in order to be converted to a proper boolean.
* This would also cause Y,N, YES, NO to be accepted as boolean types
as well.
|
|
(MAINT) fix up try_get_value acceptance test
|
|
|
|
Add a new function "try_get_value"
|
|
* Extracts a value from a deeply-nested data structure
* Returns default if a value could not be extracted
|
|
jfautley/ticket/MODULES-2478-support_root_home_fact_on_AIX
(MODULES-2478) Make root_home fact work on AIX using native lsuser command
|
|
Squashed, and amended test for comment lines.
|
|
Adds a convert_base function, which can convert numbers between bases
|
|
Squashed, improved docs, updated error handling and unit tests by David S.
|
|
* Add default value support
Second argument will be returned if yaml cannot be parsed
instead of false value
* Update tests
|
|
Consistent Readme
|
|
Remove trailing whitespace
Two functions had not been given any *Type* information. This commit fixes that.
|
|
(MAINT) improve base64 unit tests
|
|
|
|
(MODULES-2456) Modify union to accept more than two arrays
|
|
Add spec tests to test the new functionality:
*Case for 3 arrays.
*Case for 4 arrays.
Modify README to note new functionality.
This is for issue MODULE-2456, follow the precedent of MODULE-444.
This change allows union to be much more useful, unioning many arrays
in one line rather than in n lines. Additionally, as this is only added
functionality, and does not affect the 2 array case that all modules
currently using array are using, it should not affect any existing
modules utilizing union.
This is now useful, for example, for merging many arrays of resources
(eg: packages.) to generate just one list with no duplicates, to avoid
duplicate resource declarations.
|
|
This returns the default provider Puppet will choose to manage services
on this system by instantiating a dummy service resource type and
returning the provider chosen.
Co-Authored-By: Simon Fraser University <asa188@sfu.ca>
|
|
(MODULES-2410) Add new functions dos2unix and unix2dos
|
|
|
|
[MODULES-2370] allow `match` parameter to influence `ensure => absent` behavior.
|
|
Mergeback 4.8.x
|
|
|
|
Sometimes this exits 1
|
|
|
|
Fix extraneous end
|
|
|
|
Prep 4.8.0
|
|
|
|
Split the `destroy` method of the file_type::ruby provider into two
private methods: `handle_destroy_line` which is the same as the previous
`destroy` method, and `handle_destroy_with_match` which will destroy any
line which matches the `match` parameter, raising an error if multiple
lines match and the `multiple` parameter is not `true`. This new
behavior is only used if the new boolean parameter `match_for_absence`
is `true` (it defaults to `false`).
|
|
(MODULES-2316) Change file_type boolean parameter to symbols
|
|
Puppet's boolean parameter type is only available in Puppet 3.3 and
higher, so change file_type's new "replace" parameter to a regular
parameter with true and false as possible values. This matches the
existing "multiple" parameter.
|
|
Add load_metadata_json function
|
|
This function loads the metadata.json into a puppet variable. This enables a number of neat things such as:
* Which version of the module am I using? 2.x? 3.x?
* Which author of the module am I using? puppetlabs? example42?
|
|
Remove colorful language from module.
|
|
|
|
[#puppethack] Adding replace attribute to file_line
|
|
4.7.x
|
|
|
|
(maint) use puppet's utility function instead of API that's not avail…
|
|
all rubies
|
|
Fixup acceptance testing
|
|
Style fixes
|
|
|
|
|