Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require 'rubygems'
- require 'ruote'
- # preparing the engine
- engine = Ruote::Engine.new(
- Ruote::Worker.new(
- Ruote::HashStorage.new))
- pdef = Ruote.process_definition :name => 'test' do
- # literal output
- echo 'test'
- # top-level variable
- echo '${foo}'
- # or use f: prefix
- echo '${f:foo}'
- # variable in a hash?
- echo '${f:foo_hash["key"]}'
- end
- # launching, creating a process instance
- wfid = engine.launch(pdef,
- 'foo' => 'bar',
- 'foo_hash' => {'key' => 'value'})
- engine.wait_for(wfid)
Add Comment
Please, Sign In to add comment