Method: Git::Base#push
- Defined in:
- lib/git/base.rb
#push(remote = 'origin', branch = 'master', opts = {})
pushes changes to a remote repository - easiest if this is a cloned repository, otherwise you may have to run something like this first to setup the push parameters:
@git.config('remote.remote-name.push', 'refs/heads/master:refs/heads/master')
364 365 366 367 368 369 |
# File 'lib/git/base.rb', line 364 def push(remote = 'origin', branch = 'master', opts = {}) # Small hack to keep backwards compatibility with the 'push(remote, branch, tags)' method signature. opts = {:tags => opts} if [true, false].include?(opts) self.lib.push(remote, branch, opts) end |