summaryrefslogtreecommitdiffstats
path: root/subcmds/start.py
diff options
context:
space:
mode:
authorMike Frysinger <vapier@google.com>2021-03-23 20:27:29 -0400
committerMike Frysinger <vapier@google.com>2021-03-24 00:32:04 +0000
commitd1e4fa7015379cfa3c7ee0fe091bc5910754425f (patch)
tree6cbe046536fcfeb20b5a743199e6c9b2cf187a20 /subcmds/start.py
parent323b113f55a5daa6cd633a5252632c2e1ee629c7 (diff)
downloadgit-repo-d1e4fa7015379cfa3c7ee0fe091bc5910754425f.tar.gz
start: add a --HEAD alias
This makes it easy to use --H as a shortcut, and kind of matches the use of storing HEAD as the revision. Change-Id: I590bf488518f313e7a593853140316df98262d7e Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/301163 Reviewed-by: Michael Mortensen <mmortensen@google.com> Tested-by: Mike Frysinger <vapier@google.com>
Diffstat (limited to 'subcmds/start.py')
-rw-r--r--subcmds/start.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/subcmds/start.py b/subcmds/start.py
index 25b229f1..04589fb2 100644
--- a/subcmds/start.py
+++ b/subcmds/start.py
@@ -44,7 +44,8 @@ revision specified in the manifest.
44 help='begin branch in all projects') 44 help='begin branch in all projects')
45 p.add_option('-r', '--rev', '--revision', dest='revision', 45 p.add_option('-r', '--rev', '--revision', dest='revision',
46 help='point branch at this revision instead of upstream') 46 help='point branch at this revision instead of upstream')
47 p.add_option('--head', dest='revision', action='store_const', const='HEAD', 47 p.add_option('--head', '--HEAD',
48 dest='revision', action='store_const', const='HEAD',
48 help='abbreviation for --rev HEAD') 49 help='abbreviation for --rev HEAD')
49 50
50 def ValidateOptions(self, opt, args): 51 def ValidateOptions(self, opt, args):