Skip to content

Instantly share code, notes, and snippets.

@tkawachi
Created June 14, 2012 15:45
Show Gist options
  • Select an option

  • Save tkawachi/2931074 to your computer and use it in GitHub Desktop.

Select an option

Save tkawachi/2931074 to your computer and use it in GitHub Desktop.
require 'rake'
dependency = {
'all' => ['attr 1', 'attr 2', 'attr 3', 'attr 5'],
'attr 1' => ['attr 2', 'attr 3'],
'attr 2' => ['attr 5'],
'attr 3' => [],
'attr 5' => [],
}
dependency.each_pair do |key, value|
task key => value do |t|
puts "executing #{t}"
end
end
Rake::Task['all'].invoke
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment