Class: FightClub::Repository
- Inherits:
-
Object
- Object
- FightClub::Repository
- Defined in:
- lib/fight_club/repository.rb
Instance Method Summary collapse
Instance Method Details
#update(uri, name, working_dir, git) ⇒ Object
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/fight_club/repository.rb', line 3 def update(uri, name, working_dir, git) system("mkdir -p #{working_dir}/#{name}") unless Dir.exists? "#{working_dir}/#{name}" unless File.exists?("#{working_dir}/#{name}/.gitconfig") git.clone(uri) Logger.new(STDOUT).info "Clone complete!" end git.fetch end |