Navigation Menu

Skip to content

Commit

Permalink
rebase: teach git cola rebase about --[no-]autosquash
Browse files Browse the repository at this point in the history
Signed-off-by: David Aguilar <davvid@gmail.com>
  • Loading branch information
davvid committed Mar 2, 2015
1 parent e77b075 commit 324b1e1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions bin/git-cola
Expand Up @@ -233,6 +233,13 @@ def add_rebase_command(subparser):
'resolved conflicts')
parser.add_argument('--root', default=False, action='store_true',
help='rebase all reachable commits up to the root(s)')
parser.add_argument('--autosquash', default=True, action='store_true',
help='move commits that begin with '
'squash!/fixup! under -i')
parser.add_argument('--no-autosquash', default=True, action='store_false',
dest='autosquash',
help='do not move commits that begin with '
'squash!/fixup! under -i')
parser.add_argument('--committer-date-is-author-date',
default=False, action='store_true',
help="passed to 'git am' by 'git rebase'")
Expand Down Expand Up @@ -440,6 +447,7 @@ def cmd_rebase(args):
'verify': args.verify,
'rerere_autoupdate': args.rerere_autoupdate,
'root': args.root,
'autosquash': args.autosquash,
'committer_date_is_author_date': args.committer_date_is_author_date,
'ignore_date': args.ignore_date,
'whitespace': args.whitespace,
Expand Down
2 changes: 1 addition & 1 deletion cola/cmds.py
Expand Up @@ -1100,7 +1100,7 @@ def prepare_arguments(self):
return args, kwargs

kwargs['interactive'] = True
kwargs['autosquash'] = True
kwargs['autosquash'] = self.kwargs.get('autosquash', True)
kwargs.update(self.kwargs)

if self.upstream:
Expand Down

0 comments on commit 324b1e1

Please sign in to comment.