From 55ece7815a8718507ef096db53a1e186102f1c8a Mon Sep 17 00:00:00 2001 From: David Schmitt Date: Thu, 17 Sep 2015 18:48:32 +0100 Subject: (MAINT) validate_re: Clarify docs and error message --- README.markdown | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'README.markdown') diff --git a/README.markdown b/README.markdown index 8dd57f1..1cf7b32 100644 --- a/README.markdown +++ b/README.markdown @@ -1054,6 +1054,13 @@ test, and the second argument should be a stringified regular expression (withou validate_re($::puppetversion, '^2.7', 'The $puppetversion fact value does not match 2.7') ~~~ + Note: Compilation will also abort, if the first argument is not a String. Always use + quotes to force stringification: + + ~~~ + validate_re("${::operatingsystemmajrelease}", '^[57]$') + ~~~ + *Type*: statement. #### `validate_slength` -- cgit v1.2.3