mirror of
https://github.com/kubernetes/client-go.git
synced 2025-07-19 17:39:56 +00:00
Capture git export-subst strings in version.sh for 'git archive' use.
Eliminate the need to update pkg/version/base.go on release branch tagging. Kubernetes-commit: 9a9d11bb75010f43d771bf0449d462bc153760ce
This commit is contained in:
parent
ef7f446745
commit
de49589ab5
@ -51,9 +51,13 @@ var (
|
|||||||
// semantic version is a git hash, but the version itself is no
|
// semantic version is a git hash, but the version itself is no
|
||||||
// longer the direct output of "git describe", but a slight
|
// longer the direct output of "git describe", but a slight
|
||||||
// translation to be semver compliant.
|
// translation to be semver compliant.
|
||||||
|
|
||||||
|
// NOTE: The $Format strings are replaced during 'git archive' thanks to the
|
||||||
|
// companion .gitattributes file containing 'export-subst' in this same
|
||||||
|
// directory. See also https://git-scm.com/docs/gitattributes
|
||||||
gitVersion string = "v0.0.0-master+$Format:%h$"
|
gitVersion string = "v0.0.0-master+$Format:%h$"
|
||||||
gitCommit string = "$Format:%H$" // sha1 from git, output of $(git rev-parse HEAD)
|
gitCommit string = "$Format:%H$" // sha1 from git, output of $(git rev-parse HEAD)
|
||||||
gitTreeState string = "not a git tree" // state of git tree, either "clean" or "dirty"
|
gitTreeState string = "" // state of git tree, either "clean" or "dirty"
|
||||||
|
|
||||||
buildDate string = "1970-01-01T00:00:00Z" // build date in ISO8601 format, output of $(date -u +'%Y-%m-%dT%H:%M:%SZ')
|
buildDate string = "1970-01-01T00:00:00Z" // build date in ISO8601 format, output of $(date -u +'%Y-%m-%dT%H:%M:%SZ')
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user