HG(TAG)

🌸 HG(TAG) 🌸

okay bestie, welcome to the hg tag page πŸ’– this is the Mercurial tag manual β€” the one that tells you how to slap a name on a revision so future-you actually knows what's going on. let's get into it.


✨ NAME ✨

hg tag β€” add one or more tags for the current or given revision πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

hg tag [-f] [-l] [-m TEXT] [-d DATE] [-u USER] [-r REV] NAME...

πŸ’… DESCRIPTION πŸ’…

So the whole vibe is: you're naming a particular revision using name. That's it. That's the job. ✨

Tags are literally just names for particular revisions of the repository, and ngl they're so useful β€” for comparing different revisions, for going back to significant earlier versions, and for marking branch points as releases, etc. Basically they're the little sticky notes of your repo history. πŸ“Œ

Changing an existing tag is normally disallowed, okay?? like it will not let you. use -f/--force to override that. πŸ’€

If no revision is given, the parent of the working directory is used. easy.

Now, to facilitate version control, distribution, and merging of tags, they're stored as a file named .hgtags which is managed similarly to other project files and can be hand-edited if necessary. which also means β€” heads up β€” tagging creates a new commit. yes, a whole commit. the tag is not free, bestie. 😭

The file .hg/localtags is used for local tags (not shared among repositories, so they're your little private notes, iykyk).

Tag commits are usually made at the head of a branch. If the parent of the working directory is not a branch head, hg tag aborts β€” use -f/--force to force the tag commit to be based on a non-head changeset. πŸ”₯

See hg help dates for a list of formats valid for -d/--date.

⚠️ Since tag names have priority over branch names during revision lookup, using an existing branch name as a tag name is discouraged. like. don't do that. it's giving chaos. πŸ™ˆ

Returns 0 on success. βœ…


🌈 OPTIONS 🌈

  • -f, --force β€” force tag πŸ’ͺ
  • -l, --local β€” make the tag local (just for you, not the group chat)
  • -r,--rev <REV> β€” revision to tag
  • --remove β€” remove a tag πŸ—‘οΈ
  • -e, --edit β€” invoke editor on commit messages
  • -m,--message <TEXT> β€” use text as commit message
  • -d,--date <DATE> β€” record the specified date as commit date πŸ“…
  • -u,--user <USER> β€” record the specified user as committer πŸ‘‘

and that's the whole page, babe 🫢 that was hg tag from the Mercurial manual β€” HG(TAG), top to bottom, same title as the header, same as the footer, no notes missing, periodt. go tag something iconic. πŸ’–βœ¨πŸŽ€