Skip to content

Commit

Permalink
fix(githubaction): Duplicate Release name
Browse files Browse the repository at this point in the history
  • Loading branch information
cage1016 committed Sep 2, 2023
1 parent 404f2a7 commit 886ca4e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 2 additions & 0 deletions generator/githubactions.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ func (gg *GithubActionGenerator) Generate() error {
// generate release.yml
{
m, err := te.Execute("release.yml", map[string]interface{}{
"ReleaseName": "Release",
"EnabledCodeSign": gg.Enabled_Code_Sign_Notarize,
"WorkflowName": strings.ReplaceAll(viper.GetString("workflow.name"), " ", ""),
"BundleID": viper.GetString("workflow.bundle_id"),
Expand All @@ -58,6 +59,7 @@ func (gg *GithubActionGenerator) Generate() error {
// generate with auto update release.yml
{
m, err := te.Execute("release.yml", map[string]interface{}{
"ReleaseName": "Release_auto_update",
"EnabledCodeSign": gg.Enabled_Code_Sign_Notarize,
"WorkflowName": fmt.Sprintf("%s_auto_update", strings.ReplaceAll(viper.GetString("workflow.name"), " ", "")),
"Ldflags": fmt.Sprintf("-X %s/cmd.EnabledAutoUpdate=true", viper.GetString("go_mod_package")),
Expand Down
8 changes: 4 additions & 4 deletions template/bindata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion template/tmpl/release.yml.tmpl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release
name: {{.ReleaseName}}
on:
release:
types:
Expand Down

0 comments on commit 886ca4e

Please sign in to comment.