On Friday, February 17, 2017 at 10:40:57 AM UTC-6, João Matos wrote:
>
> Hi all
>
> we're trying to assign a value to a parameter with a dollar and that is a 
> problem.
> adding a backslash only makes the string become backslashed which is not 
> what we want. Different types of quoting did seem to work either..
> I'm sure a lot of people add this issue but i couldnt find an answer on 
> search engines or this group.
>
> Any solution or simply not allowed?
>
>
The Puppet documentation describes the format for string literals 
<https://docs.puppet.com/puppet/4.9/lang_data_string.html>.  There are 
multiple ways to produce a string value that contains a '$' character, but 
we cannot easily make any specific recommendations to you because you have 
not presented the problematic Puppet code.  I'm inclined to guess that in 
your attempts to find a solution by trial & error, you made offsetting 
changes, and so missed finding a solution.

It its simplest, if you want to avoid interpolation being performed then 
using single quotes instead of double quotes to delimit your string is a 
good option:

$variable = 'I am assigned to $variable'

If that does not solve your problem then we need more information before we 
can suggest a more suitable implementation.


John

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/59e7480f-0ff4-4cb6-a637-aacbacee93f5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to