Skip to content

Commit 92fc20b

Browse files
authored
Merge pull request #1258 from puppetlabs/release-prep
Release prep v8.4.0
2 parents 4dd6a6d + 65f45c5 commit 92fc20b

File tree

3 files changed

+44
-1
lines changed

3 files changed

+44
-1
lines changed

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22

33
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).
44

5+
## [v8.4.0](https://github.com/puppetlabs/puppetlabs-stdlib/tree/v8.4.0) (2022-07-21)
6+
7+
[Full Changelog](https://github.com/puppetlabs/puppetlabs-stdlib/compare/v8.3.0...v8.4.0)
8+
9+
### Added
10+
11+
- deferrable epp function simplifying deferred templates [\#1253](https://github.com/puppetlabs/puppetlabs-stdlib/pull/1253) ([binford2k](https://github.com/binford2k))
12+
513
## [v8.3.0](https://github.com/puppetlabs/puppetlabs-stdlib/tree/v8.3.0) (2022-07-11)
614

715
[Full Changelog](https://github.com/puppetlabs/puppetlabs-stdlib/compare/v8.2.0...v8.3.0)

REFERENCE.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ the provided regular expression.
171171
* [`sort`](#sort): Sorts strings and arrays lexically.
172172
* [`sprintf_hash`](#sprintf_hash): Uses sprintf with named references.
173173
* [`squeeze`](#squeeze): Returns a new string where runs of the same character that occur in this set are replaced by a single character.
174+
* [`stdlib::deferrable_epp`](#stdlibdeferrable_epp): This function returns either a rendered template or a deferred function to render at runtime. If any of the values in the variables hash are
174175
* [`stdlib::end_with`](#stdlibend_with): Returns true if str ends with one of the prefixes given. Each of the prefixes should be a String.
175176
* [`stdlib::ensure`](#stdlibensure): function to cast ensure parameter to resource specific value
176177
* [`stdlib::extname`](#stdlibextname): Returns the Extension (the Portion of Filename in Path starting from the
@@ -4614,6 +4615,40 @@ The squeeze function.
46144615

46154616
Returns: `Any` a new string where runs of the same character that occur in this set are replaced by a single character.
46164617

4618+
### <a name="stdlibdeferrable_epp"></a>`stdlib::deferrable_epp`
4619+
4620+
Type: Puppet Language
4621+
4622+
This function returns either a rendered template or a deferred function to render at runtime.
4623+
If any of the values in the variables hash are deferred, then the template will be deferred.
4624+
4625+
Note: this function requires all parameters to be explicitly passed in. It cannot expect to
4626+
use facts, class variables, and other variables in scope. This is because when deferred, we
4627+
have to explicitly pass the entire scope to the client.
4628+
4629+
#### `stdlib::deferrable_epp(String $template, Hash $variables)`
4630+
4631+
This function returns either a rendered template or a deferred function to render at runtime.
4632+
If any of the values in the variables hash are deferred, then the template will be deferred.
4633+
4634+
Note: this function requires all parameters to be explicitly passed in. It cannot expect to
4635+
use facts, class variables, and other variables in scope. This is because when deferred, we
4636+
have to explicitly pass the entire scope to the client.
4637+
4638+
Returns: `Variant[String, Deferred]`
4639+
4640+
##### `template`
4641+
4642+
Data type: `String`
4643+
4644+
4645+
4646+
##### `variables`
4647+
4648+
Data type: `Hash`
4649+
4650+
4651+
46174652
### <a name="stdlibend_with"></a>`stdlib::end_with`
46184653

46194654
Type: Ruby 4.x API

metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "puppetlabs-stdlib",
3-
"version": "8.3.0",
3+
"version": "8.4.0",
44
"author": "puppetlabs",
55
"summary": "Standard library of resources for Puppet modules.",
66
"license": "Apache-2.0",

0 commit comments

Comments
 (0)