On Thu, Mar 4, 2010 at 5:43 PM, Peter Meier <peter.me...@immerda.ch> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
>>> Well, it workes in erb test, but not when puppet runs:
>>>
>>> undefined method `start_with?' for....  via puppet
>>>
>>> erb -x -T '-' test.erb | ruby -c  says Syntax OK....
>>
>> I thought 'start_with" was a ruby 1.9 thing only? And "starts_with" is
>> a Rails-ism ?
>
> exactly.

No, don't think so:

~ $ irb
>> RUBY_VERSION
=> "1.8.7"
>> "foo".start_with?("fo")
=> true
>> ^D~ $

[ this is on Snow Leopard, mind, ] I'm not sure how much of Ruby you can
use in ERB templates, but I'd have thought if a language feature works
on irb, it'll work in templates run on that machine.

Templates are expanded on the puppetmaster, right?

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-us...@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to