Module: Phase::Util::Shell

Includes:
Console
Included in:
Deploy::Build
Defined in:
lib/phase/util/shell.rb

Instance Method Summary collapse

Methods included from Console

#ask, #fail, #log

Instance Method Details

#shell(*args) {|$?| ... } ⇒ Object

Yields:

  • ($?)


6
7
8
9
10
11
# File 'lib/phase/util/shell.rb', line 6

def shell(*args)
  log "running: #{args.join(' ')}"
  status = !!system(*args)
  yield $? unless status
  return status
end