readTag
Read an annotated tag object directly
param | type [= default] | description |
---|---|---|
core | string = 'default' | The plugin core identifier to use for plugin injection |
fs [deprecated] | FileSystem | The filesystem containing the git repo. Overrides the fs provided by the plugin system. |
dir | string | The working tree directory path |
gitdir | string = join(dir,'.git') | The git directory path |
oid | string | The SHA-1 object id to get |
return | Promise<ReadTagResult> | Resolves successfully with a git object description |
The object returned has the following schema:
type ReadTagResult = {
oid: string; // SHA-1 object id of this tag
tag: TagObject; // the parsed tag object
payload: string; // PGP signing payload
}
type TagObject = {
object: string; // SHA-1 object id of object being tagged
type: 'blob' | 'tree' | 'commit' | 'tag'; // the type of the object being tagged
tag: string; // the tag name
tagger: {
name: string; // the tagger's name
email: string; // the tagger's email
timestamp: number; // UTC Unix timestamp in seconds
timezoneOffset: number; // timezone difference from UTC in minutes
};
message: string; // tag message
signature?: string; // PGP signature (if present)
}