module Boilerpl8::ShellHelper
Public Instance Methods
chdir(dir, &block)
click to toggle source
# File lib/boilerpl8.rb, line 36 def chdir(dir, &block) puts "$ cd #{dir}" Dir.chdir(dir, &block) puts "$ cd -" end
mv(oldpath, newpath)
click to toggle source
# File lib/boilerpl8.rb, line 26 def mv(oldpath, newpath) puts "$ mv #{oldpath} #{newpath}" File.rename oldpath, newpath end
rm_rf(path)
click to toggle source
# File lib/boilerpl8.rb, line 21 def rm_rf(path) puts "$ rm -rf #{path}" FileUtils.rm_rf path end
sys(command)
click to toggle source
# File lib/boilerpl8.rb, line 31 def sys(command) puts "$ #{command}" system command end