diff options
author | Nico Weber <nicolasweber@gmx.de> | 2019-08-21 15:41:20 +0000 |
---|---|---|
committer | Nico Weber <nicolasweber@gmx.de> | 2019-08-21 15:41:20 +0000 |
commit | 862c94297c022af6919faa283ce94c80363ed92d (patch) | |
tree | fc5e9a8eca40906ce69604907f673e40e080d61f /llvm/utils/git-svn/git-llvm | |
parent | e2b200b7bfa1f4ae2606f375fd7eb7f44cc208fc (diff) | |
download | bcm5719-llvm-862c94297c022af6919faa283ce94c80363ed92d.tar.gz bcm5719-llvm-862c94297c022af6919faa283ce94c80363ed92d.zip |
git-llvm: Give "push" a --force flag to disable confirm prompt on multiple commits
llvm-svn: 369538
Diffstat (limited to 'llvm/utils/git-svn/git-llvm')
-rwxr-xr-x | llvm/utils/git-svn/git-llvm | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/llvm/utils/git-svn/git-llvm b/llvm/utils/git-svn/git-llvm index 0d1220e845c..e30d17c78a1 100755 --- a/llvm/utils/git-svn/git-llvm +++ b/llvm/utils/git-svn/git-llvm @@ -471,7 +471,7 @@ def cmd_push(args): for c in revs))) # Ask confirmation if multiple commits are about to be pushed - if len(revs) != 1: + if not args.force and len(revs) != 1: if not ask_confirm("Are you sure you want to create %d commits?" % len(revs)): die("Aborting") @@ -627,6 +627,11 @@ if __name__ == '__main__': 'repo, so probably will not work well if you try to commit more ' 'than one rev.') parser_push.add_argument( + '-f', + '--force', + action='store_true', + help='Do not ask for confirmation when pushing multiple commits.') + parser_push.add_argument( 'rev_range', metavar='GIT_REVS', type=str, |