Class: Gonzui::Git
- Inherits:
-
AbstractVCS
- Object
- AbstractVCS
- Gonzui::Git
- Defined in:
- lib/gonzui/vcs.rb
Instance Method Summary collapse
- #do_checkout(output_directory) ⇒ Object
- #do_update(output_directory) ⇒ Object
-
#initialize(config, root, mozule = nil) ⇒ Git
constructor
A new instance of Git.
Methods inherited from AbstractVCS
Methods included from Util
assert, assert_equal, assert_equal_all, assert_non_nil, assert_not_reached, benchmark, command_exist?, commify, eprintf, format_bytes, program_name, protect_from_signals, require_command, set_verbosity, shell_escape, unix?, vprintf, windows?, wprintf
Constructor Details
Instance Method Details
#do_checkout(output_directory) ⇒ Object
114 115 116 117 118 119 120 |
# File 'lib/gonzui/vcs.rb', line 114 def do_checkout(output_directory) Dir.chdir(@config.cache_directory) { command_line = sprintf("git clone %s", shell_escape(@root)) run_command(command_line, "git clone") } end |
#do_update(output_directory) ⇒ Object
122 123 124 125 126 |
# File 'lib/gonzui/vcs.rb', line 122 def do_update(output_directory) Dir.chdir(output_directory) { run_command("git pull","git pull") } end |