Module: Beet::SCM
- Included in:
- Executor
- Defined in:
- lib/beet/scm.rb
Instance Method Summary collapse
-
#git(command = {}) ⇒ Object
Run a command in git.
Instance Method Details
#git(command = {}) ⇒ Object
Run a command in git.
Examples
git :init
git :add => "this.file that.rb"
git :add => "onefile.rb", :rm => "badfile.cxx"
22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/beet/scm.rb', line 22 def git(command = {}) in_root do if command.is_a?(Symbol) log 'running', "git #{command}" Git.run(command.to_s) else command.each do |command, | log 'running', "git #{command} #{}" Git.run("#{command} #{}") end end end end |