Class: Git

Inherits:
Scm
  • Object
show all
Defined in:
lib/beet/scm/git.rb

Class Method Summary collapse

Class Method Details

.clone(repos, branch = nil) ⇒ Object



2
3
4
5
6
7
8
9
# File 'lib/beet/scm/git.rb', line 2

def self.clone(repos, branch=nil)
  system("git clone #{repos}")

  if branch
    system("cd #{repos.split('/').last}/")
    system("git checkout #{branch}")
  end
end

.run(command) ⇒ Object



11
12
13
# File 'lib/beet/scm/git.rb', line 11

def self.run(command)
  system("git #{command}")
end