Class: EacGit::Local::Remote::Push

Inherits:
Object
  • Object
show all
Defined in:
lib/eac_git/local/remote/push.rb

Instance Method Summary collapse

Instance Method Details

#git_command_argsEnumerable<String>

Returns:

  • (Enumerable<String>)


25
26
27
28
29
# File 'lib/eac_git/local/remote/push.rb', line 25

def git_command_args
  r = ['push', remote.name]
  r << '--force' if force?
  r + refspecs
end

#immutable_constructor_argsArray<Object>

Returns:

  • (Array<Object>)


15
16
17
# File 'lib/eac_git/local/remote/push.rb', line 15

def immutable_constructor_args
  [remote]
end

#performvoid

This method returns an undefined value.



20
21
22
# File 'lib/eac_git/local/remote/push.rb', line 20

def perform
  local.command(*git_command_args).system!
end