Module: Babushka::GitHelpers
- Included in:
- BaseDepRunner, Source
- Defined in:
- lib/babushka/helpers/git_helpers.rb
Instance Method Summary (collapse)
Instance Method Details
- (Object) git(uri, opts = {}, &block)
3 4 5 6 7 8 9 10 |
# File 'lib/babushka/helpers/git_helpers.rb', line 3 def git uri, opts = {}, &block repo = GitRepo.new(opts[:to] || (BuildPrefix / File.basename(uri.to_s).chomp('.git'))) if git_update(uri, repo) repo.root.touch # so we can tell when it was last updated block.nil? || cd(repo.path, &block) end end |