Created
August 18, 2013 16:20
-
-
Save benhoskings/6262473 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dep 'erb config', :src, :dest do | |
met? { | |
Babushka::Renderable.new(dest).from?(dependency.load_path.parent / src) | |
} | |
meet { | |
render_erb src, :to => dest | |
} | |
end | |
dep 'app' do | |
requires [ | |
'app.bin', | |
'erb config'.with('app/app.conf.erb', '/etc/app.conf') | |
] | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I suspect this will not work if the template erb is not relative to the source file of the source containing this dep, because it uses dependency.load_path.