Module: Hubeye::Hooks::Default

Defined in:
lib/hubeye/hooks/git_hooks.rb

Class Method Summary collapse

Class Method Details

.fetch(local_reponame, remotename, branchname) ⇒ Object



5
6
7
8
9
# File 'lib/hubeye/hooks/git_hooks.rb', line 5

def self.fetch(local_reponame, remotename, branchname)
  Dir.chdir(File.expand_path(local_reponame)) do
    ::Kernel.system("git fetch #{remotename} #{branchname}")
  end
end

.pull(local_reponame, remotename, branchname) ⇒ Object



11
12
13
14
15
# File 'lib/hubeye/hooks/git_hooks.rb', line 11

def self.pull(local_reponame, remotename, branchname)
  Dir.chdir(File.expand_path(local_reponame)) do
    ::Kernel.system("git pull #{remotename} #{branchname}")
  end
end