Skip to content

Commit

Permalink
[chore] update files
Browse files Browse the repository at this point in the history
  • Loading branch information
Dainerx committed Jan 7, 2025
1 parent ee35153 commit 6375e02
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions cmd/builder/internal/builder/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ type Config struct {
SkipGetModules bool `mapstructure:"-"`
SkipStrictVersioning bool `mapstructure:"-"`
LDFlags string `mapstructure:"-"`
LDSet bool `mapstructure:"-"` // only used to override LDFlags
LDSet bool `mapstructure:"-"` // only used to override LDFlags
GCFlags string `mapstructure:"-"`
GCSet bool `mapstructure:"-"` // only used to override GCFlags
GCSet bool `mapstructure:"-"` // only used to override GCFlags
Verbose bool `mapstructure:"-"`

Distribution Distribution `mapstructure:"dist"`
Expand Down
6 changes: 3 additions & 3 deletions cmd/builder/internal/builder/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,8 @@ func Compile(cfg *Config) error {

cfg.Logger.Info("Compiling")

var ldflags = "-s -w" // we strip the symbols by default for smaller binaries
var gcflags = ""
ldflags := "-s -w" // we strip the symbols by default for smaller binaries
gcflags := ""

args := []string{"build", "-trimpath", "-o", cfg.Distribution.Name}
if cfg.Distribution.DebugCompilation {
Expand All @@ -127,7 +127,7 @@ func Compile(cfg *Config) error {
gcflags = cfg.GCFlags
}

Check warning on line 128 in cmd/builder/internal/builder/main.go

View check run for this annotation

Codecov / codecov/patch

cmd/builder/internal/builder/main.go#L126-L128

Added lines #L126 - L128 were not covered by tests
}

args = append(args, "-ldflags="+ldflags)
args = append(args, "-gcflags="+gcflags)

Expand Down

0 comments on commit 6375e02

Please sign in to comment.