##// END OF EJS Templates
tag: disallow tagging the working directory...
Matt Harbison -
r50982:4fc6b423 stable
parent child Browse files
Show More
@@ -7472,6 +7472,9 b' def tag(ui, repo, name1, *names, **opts)'
7472 )
7472 )
7473 node = logcmdutil.revsingle(repo, rev_).node()
7473 node = logcmdutil.revsingle(repo, rev_).node()
7474
7474
7475 if node is None:
7476 raise error.InputError(_(b"cannot tag working directory"))
7477
7475 if not message:
7478 if not message:
7476 # we don't translate commit messages
7479 # we don't translate commit messages
7477 message = b'Added tag %s for changeset %s' % (
7480 message = b'Added tag %s for changeset %s' % (
@@ -412,6 +412,10 b' tagging on null rev'
412 abort: cannot tag null revision
412 abort: cannot tag null revision
413 [10]
413 [10]
414
414
415 $ hg tag -R empty -r "wdir()" -f wdirtag
416 abort: cannot tag working directory
417 [10]
418
415 issue5539: pruned tags do not appear in .hgtags
419 issue5539: pruned tags do not appear in .hgtags
416
420
417 $ cat >> $HGRCPATH << EOF
421 $ cat >> $HGRCPATH << EOF
General Comments 0
You need to be logged in to leave comments. Login now