Parsed representation of a git tag.
Contains the tag name, whether it is annotated, the tagger name and email (for annotated tags), the date, and the annotation message.
Summary
Types
Functions
@spec format_string() :: String.t()
Returns the --format string used by git tag -l for detailed output.
Uses ASCII control characters as delimiters for reliable parsing.
Parses the output of git tag -l --format=... with the detailed format string.
Examples
iex> Git.Tag.parse_detailed("")
[]
Parses the output of git tag -l -n1 into a list of Git.Tag structs.
Each line has the form:
v1.0.0 first release
v1.1.0 second releaseTags with an annotation message are marked as annotated. Lightweight tags
have no message in -n1 output (or the message matches the commit subject).
Examples
iex> Git.Tag.parse_list("v1.0.0\nv1.1.0\n")
[%Git.Tag{name: "v1.0.0", annotated: false}, %Git.Tag{name: "v1.1.0", annotated: false}]