Top Level Namespace

Defined Under Namespace

Modules: S4tUtils, Test Classes: HoeLike, String

Constant Summary collapse

S4TUtils =

Tolerate typos

S4tUtils
S4tUtil =
S4tUtils
S4TUtil =
S4tUtils

Instance Method Summary collapse

Instance Method Details

#assert_in(dir, taskname) ⇒ Object

These are at the top level so that they can be available in the context of a running task.



10
11
12
13
14
15
# File 'lib/s4t-utils/hoelike.rb', line 10

def assert_in(dir, taskname) # :nodoc:
  unless Dir.pwd == dir
    puts "Run task '#{taskname}' from directory '#{dir}'."
    exit 1
  end
end

#confirmed_step(name) ⇒ Object

:nodoc:



17
18
19
20
21
22
# File 'lib/s4t-utils/hoelike.rb', line 17

def confirmed_step(name) # :nodoc:
  STDOUT.puts "** #{name} **"
  STDOUT.puts `rake #{name}`
  STDOUT.print 'OK? > '
  exit if STDIN.readline =~ /[nN]/
end