Tuesday, 20 August 2013

Putting the callback on the same line?

Putting the callback on the same line?

I'm not a Ruby developer by any means and am just modifying a Chef recipe.
I'm curious, is it possible to put the following onto one line?
directory "/var/lib/mysql" do
action :delete
end
I tried this:
directory "/var/lib/mysql", :action => "delete"
However, that throws this error:
ArgumentError
-------------
wrong number of arguments (3 for 2)

No comments:

Post a Comment