Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save benhoskings/305550 to your computer and use it in GitHub Desktop.
Save benhoskings/305550 to your computer and use it in GitHub Desktop.
# dynamic removal of a dep requirement,
# based on a condition evaluated after previous requires have been processed
dep 'site' do
requires [
'system',
'account',
'site dir',
'site options'
]
end
dep 'site options' do
setup {
definer.requires 'rvm user' if confirm "System ruby is #{shell 'ruby -v'}; do you want to install your own in an RVM?"
}
end
dep 'rvm user' do
# ...
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment