Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Separator defaults

  • Loading branch information...
commit ddb449c2e924e3fc8c4421ae895a469a0e34e399 1 parent 66fd5ed
@winton authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/execache.rb
View
4 lib/execache.rb
@@ -65,7 +65,9 @@ def initialize(yaml)
hash[cmd_type] = []
if cmd_options['cmd']
- separators = options[cmd_type]['separators']
+ separators = options[cmd_type]['separators'] || {}
+ separators['group'] ||= "[END]"
+ separators['result'] ||= "\n"
output = `#{cmd_options['cmd']}`
output = output.split(separators['group'] + separators['result'])
output = output.collect { |r| r.split(separators['result']) }
Please sign in to comment.
Something went wrong with that request. Please try again.