Class: GitCommands::Rebase
- Includes:
- GitCommands
- Defined in:
- lib/straight_line/common/git_commands/rebase.rb
Overview
Rebase a branch to a base
Instance Attribute Summary
Attributes inherited from Command
Instance Method Summary collapse
-
#initialize(base, branch) ⇒ Rebase
constructor
A new instance of Rebase.
- #run(*_args) ⇒ Object
Methods included from GitCommands
Methods inherited from Command
#arg, from_file, #run_sub_commands, #sub_command
Constructor Details
#initialize(base, branch) ⇒ Rebase
Returns a new instance of Rebase.
9 10 11 12 13 14 |
# File 'lib/straight_line/common/git_commands/rebase.rb', line 9 def initialize(base, branch) super('git') arg 'rebase' arg base arg branch end |
Instance Method Details
#run(*_args) ⇒ Object
16 17 18 19 20 |
# File 'lib/straight_line/common/git_commands/rebase.rb', line 16 def run(*_args) super true rescue ShellError => e handle_merge_conflict(e) end |