Closed jamiejackson closed 10 years ago
Hi!
I've added a simple example for running a command after vagrant destroy
to README:
https://github.com/emyl/vagrant-triggers#a-simple-example
You can also embed some inline ruby, a quick example could be:
config.trigger.before :up do
random_number = Random.rand(100)
info "Number drawn: ${random_number}"
end
Keep in mind that your ruby code will always run in the context of an instance of the DSL class.
I'm having trouble doing some simple things, both because I'm a Ruby noob, and because I can find only two vagrant-triggers examples on the internet (and their syntaxes seem to conflict).
Could you provide an example for, say:
ls -al
.