1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
module Rails class Git < Scm def self.clone(repos, branch=nil) `git clone #{repos}` if branch `cd #{repos.split('/').last}/` `git checkout #{branch}` end end def self.run(command) `git #{command}` end end end