mirror of
https://code.tvl.fyi/depot.git:/tools/nixery.git
synced 2025-04-26 18:23:53 +00:00
feat(nixery): default to HEAD to support other default branches
Change-Id: Id8407026fb103701129dc1a2f009ab2388f55122 Reviewed-on: https://cl.tvl.fyi/c/depot/+/13326 Reviewed-by: tazjin <tazjin@tvl.su> Autosubmit: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
This commit is contained in:
parent
a857edaf71
commit
c6d4692b1b
|
@ -50,10 +50,9 @@ func (g *GitSource) Render(tag string) (string, string) {
|
|||
}
|
||||
|
||||
// The 'git' source requires a tag to be present. If the user
|
||||
// has not specified one, it is assumed that the default
|
||||
// 'master' branch should be used.
|
||||
// has not specified one, it is assumed that 'HEAD' should be used.
|
||||
if tag == "latest" || tag == "" {
|
||||
tag = "master"
|
||||
tag = "HEAD"
|
||||
}
|
||||
|
||||
if commitRegex.MatchString(tag) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user