Summary
libra tag <name> <commit> is rejected, so a tag can only be created at HEAD. Git accepts an explicit target (git tag <name> <commit>, git tag -m <msg> <name> <commit>).
Reproduction (libra 0.22.33)
libra init --vault false
printf 'base\n' > a.txt && libra add a.txt && libra commit -m init
libra branch side
printf 'main\n' > a.txt && libra add a.txt && libra commit -m m
libra tag vside side
# error: unexpected argument 'side' found
# Usage: libra tag [OPTIONS] [NAME] (exit 129, LBR-CLI-002)
libra tag -m msg vann side # same error
libra rev-parse vside # not a valid object name: 'vside'
Scripts that pass a target silently end up without the tag, and a later libra merge vside or libra merge refs/tags/vside then fails with not something we can merge (exit 129), which looks like a merge problem even though tag merges work once the tag exists.
Git 2.54.0
git tag vside side creates refs/tags/vside pointing at side; git tag -m msg vann side creates an annotated tag whose object points at side.
Expected
Accept an optional <commit> (any commit-ish, including branch names and other tags) after <name> for lightweight and annotated tags (-m, -F, -s, -f), resolve it like other revision arguments, and keep creating at HEAD when it is omitted. The clap definition is TagArgs in src/command/tag.rs:41-44 (a single optional name).
Found while measuring behavior for #477; it is outside that plan's scope.
Summary
libra tag <name> <commit>is rejected, so a tag can only be created atHEAD. Git accepts an explicit target (git tag <name> <commit>,git tag -m <msg> <name> <commit>).Reproduction (libra 0.22.33)
Scripts that pass a target silently end up without the tag, and a later
libra merge vsideorlibra merge refs/tags/vsidethen fails withnot something we can merge(exit 129), which looks like a merge problem even though tag merges work once the tag exists.Git 2.54.0
git tag vside sidecreatesrefs/tags/vsidepointing atside;git tag -m msg vann sidecreates an annotated tag whose object points atside.Expected
Accept an optional
<commit>(any commit-ish, including branch names and other tags) after<name>for lightweight and annotated tags (-m,-F,-s,-f), resolve it like other revision arguments, and keep creating atHEADwhen it is omitted. The clap definition isTagArgsinsrc/command/tag.rs:41-44(a single optionalname).Found while measuring behavior for #477; it is outside that plan's scope.