Skip to content

Commit

Permalink
cdep: fix yaml branch regex replace
Browse files Browse the repository at this point in the history
  • Loading branch information
julesjcraske committed May 22, 2024
1 parent 4eb781d commit fd20c43
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/cdep/app/add_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ var branchRegAdd = regexp.MustCompile(`"branch"\s*:\s*"([^"]+)"`)

var commitRegAddYaml = regexp.MustCompile(`commit\s*:\s*"?[a-f\d]{40}"?`)
var imageTagRegAddYaml = regexp.MustCompile(`tag\s*:\s*"?[a-z\d-]+"?`)
var branchRegAddYaml = regexp.MustCompile(`branch\s*:\s*"?([a-z\d-\.]+)"?`)
var branchRegAddYaml = regexp.MustCompile(`branch\s*:\s*"?([a-zA-Z\d-._]+)"?`)

func (a App) AddToConfig(path, branchName, commitHash string) (bool, error) {
blob, err := os.ReadFile(path)
Expand Down

0 comments on commit fd20c43

Please sign in to comment.