Skip to content

Release prep v8.5.0 #1276

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,25 @@

All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org).

## [v8.5.0](https://github.com/puppetlabs/puppetlabs-stdlib/tree/v8.5.0) (2022-10-13)

[Full Changelog](https://github.com/puppetlabs/puppetlabs-stdlib/compare/v8.4.0...v8.5.0)

### Added

- Add a Stdlib::CreateResources type [\#1267](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1267) ([ekohl](https://github.com/ekohl))
- pdksync - \(GH-cat-11\) Certify Support for Ubuntu 22.04 [\#1261](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1261) ([david22swan](https://github.com/david22swan))
- \(FEAT\) Add function parsepson [\#1259](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1259) ([david22swan](https://github.com/david22swan))

### Fixed

- \(CONT-200\) Fix require relative paths [\#1275](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1275) ([chelnak](https://github.com/chelnak))
- pdksync - \(CONT-189\) Remove support for RedHat6 / OracleLinux6 / Scientific6 [\#1272](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1272) ([david22swan](https://github.com/david22swan))
- pdksync - \(CONT-130\) - Dropping Support for Debian 9 [\#1269](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1269) ([jordanbreen28](https://github.com/jordanbreen28))
- \(MAINT\) Drop support for AIX + Windows EOL OSs [\#1265](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1265) ([jordanbreen28](https://github.com/jordanbreen28))
- \(GH-1262\) Use 'require\_relative' to load stdlib due to lookup errors [\#1264](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1264) ([david22swan](https://github.com/david22swan))
- Switch parsejson\(\) from PSON to JSON parsing [\#1240](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1240) ([seanmil](https://github.com/seanmil))

## [v8.4.0](https://github.com/puppetlabs/puppetlabs-stdlib/tree/v8.4.0) (2022-07-21)

[Full Changelog](https://github.com/puppetlabs/puppetlabs-stdlib/compare/v8.3.0...v8.4.0)
Expand Down
70 changes: 49 additions & 21 deletions REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,8 @@ true boolean.
Puppet structure
* [`parsejson`](#parsejson): This function accepts JSON as a string and converts it into the correct
Puppet structure.
* [`parsepson`](#parsepson): This function accepts PSON, a Puppet variant of JSON, as a string and
converts it into the correct Puppet structure.
* [`parsepson`](#parsepson): This function accepts PSON, a Puppet variant of JSON, as a string and converts
it into the correct Puppet structure
* [`parseyaml`](#parseyaml): This function accepts YAML as a string and converts it into the correct
Puppet structure.
* [`pick`](#pick): This function will return
Expand Down Expand Up @@ -272,6 +272,7 @@ OpenSSL.
* [`Stdlib::Compat::Ipv6`](#stdlibcompatipv6): Validate an IPv6 address
* [`Stdlib::Compat::Numeric`](#stdlibcompatnumeric): Emulate the is_numeric and validate_numeric functions
* [`Stdlib::Compat::String`](#stdlibcompatstring): Emulate the is_string and validate_string functions
* [`Stdlib::CreateResources`](#stdlibcreateresources): A type description used for the create_resources function
* [`Stdlib::Datasize`](#stdlibdatasize): Validate the size of data
* [`Stdlib::Email`](#stdlibemail): Validate an e-mail address
* [`Stdlib::Ensure::File`](#stdlibensurefile): Validate the value of the ensure parameter for a file
Expand Down Expand Up @@ -3923,30 +3924,24 @@ Type: Ruby 3.x API

> *Note:*
The optional second argument can be used to pass a default value that will
be returned if the parsing of YAML string have failed.
be returned if the parsing of the JSON string failed or if the JSON parse
evaluated to nil.

#### `parsejson()`

> *Note:*
The optional second argument can be used to pass a default value that will
be returned if the parsing of YAML string have failed.
be returned if the parsing of the JSON string failed or if the JSON parse
evaluated to nil.

Returns: `Any` convert JSON into Puppet structure

### <a name="parseyaml"></a>`parseyaml`

Type: Ruby 3.x API

> *Note:*
The optional second argument can be used to pass a default value that will
be returned if the parsing of YAML string have failed.

### <a name="parsepson"></a>`parsepson`

Type: Ruby 4.x API

This function accepts PSON as a string and converts it into the correct
Puppet structure
For more information on PSON please see the following link:
https://puppet.com/docs/puppet/7/http_api/pson.html

#### Examples

Expand All @@ -3956,13 +3951,11 @@ Puppet structure
$data = parsepson('{"a":"1","b":"2"}')
```

#### `parsepson(String[1] $pson_string, Optional[Any] $default)`

For more information on PSON please see the following link:
https://puppet.com/docs/puppet/7/http_api/pson.html

#### `parsepson(String $pson_string, Optional[Any] $default)`

The parseson function.

Returns: `Data`

##### Examples
Expand All @@ -3973,9 +3966,6 @@ Returns: `Data`
$data = parsepson('{"a":"1","b":"2"}')
```

For more information on PSON please see the following link:
https://puppet.com/docs/puppet/7/http_api/pson.html

##### `pson_string`

Data type: `String[1]`
Expand All @@ -3988,6 +3978,14 @@ Data type: `Optional[Any]`

An optional default to return if parsing the pson_string fails

### <a name="parseyaml"></a>`parseyaml`

Type: Ruby 3.x API

> *Note:*
The optional second argument can be used to pass a default value that will
be returned if the parsing of YAML string have failed.

#### `parseyaml()`

> *Note:*
Expand Down Expand Up @@ -7604,6 +7602,36 @@ Alias of
Optional[String]
```

### <a name="stdlibcreateresources"></a>`Stdlib::CreateResources`

A type description used for the create_resources function

#### Examples

##### As a class parameter

```puppet
class myclass (
Stdlib::CreateResources $myresources = {},
) {
# Using create_resources
create_resources('myresource', $myresources)

# Using iteration
$myresources.each |$myresource_name, $myresource_attrs| {
myresource { $myresource_name:
* => $myresource_attrs,
}
}
}
```

Alias of

```puppet
Hash[String[1], Hash[String[1], Any]]
```

### <a name="stdlibdatasize"></a>`Stdlib::Datasize`

Validate the size of data
Expand Down
2 changes: 1 addition & 1 deletion metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "puppetlabs-stdlib",
"version": "8.4.0",
"version": "8.5.0",
"author": "puppetlabs",
"summary": "Standard library of resources for Puppet modules.",
"license": "Apache-2.0",
Expand Down