Skip to content

Commit 1d6b67f

Browse files
authored
Merge pull request #255935 from Homebrew/std_go_args_omit_ldflags
various: omit `ldflags` argument in `std_go_args` method
2 parents 86b2b7f + 029e890 commit 1d6b67f

File tree

11 files changed

+11
-11
lines changed

11 files changed

+11
-11
lines changed

Formula/b/bitrise.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def install
3131
-X github.com/bitrise-io/bitrise/version.Commit=#{tap.user}
3232
]
3333

34-
system "go", "build", *std_go_args(ldflags: ldflags)
34+
system "go", "build", *std_go_args(ldflags:)
3535
end
3636

3737
test do

Formula/b/bom.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def install
2323
-X sigs.k8s.io/release-utils/version.gitVersion=v#{version}
2424
-X sigs.k8s.io/release-utils/version.gitTreeState=clean
2525
]
26-
system "go", "build", *std_go_args(ldflags: ldflags.join(" ")), "./cmd/bom"
26+
system "go", "build", *std_go_args(ldflags:), "./cmd/bom"
2727

2828
generate_completions_from_executable(bin/"bom", "completion", shells: [:bash, :zsh, :fish, :pwsh])
2929
end

Formula/d/dnscontrol.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def install
3131
-s -w
3232
-X github.com/StackExchange/dnscontrol/v4/pkg/version.version=#{version}
3333
]
34-
system "go", "build", *std_go_args(ldflags: ldflags)
34+
system "go", "build", *std_go_args(ldflags:)
3535

3636
generate_completions_from_executable(bin/"dnscontrol", "shell-completion", shells: [:bash, :zsh])
3737
end

Formula/g/gh-ost.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class GhOst < Formula
2626

2727
def install
2828
ldflags = "-s -w -X main.AppVersion=#{version} -X main.GitCommit=#{tap.user}"
29-
system "go", "build", *std_go_args(ldflags: ldflags), "./go/cmd/gh-ost"
29+
system "go", "build", *std_go_args(ldflags:), "./go/cmd/gh-ost"
3030
end
3131

3232
test do

Formula/g/go-librespot.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def install
3535
]
3636
ldflags << "-X github.com/devgianlu/go-librespot.commit=#{Utils.git_short_head(length: 8)}" if build.head?
3737

38-
system "go", "build", *std_go_args(output: bin/"go-librespot", ldflags: ldflags), "./cmd/daemon"
38+
system "go", "build", *std_go_args(output: bin/"go-librespot", ldflags:), "./cmd/daemon"
3939
(var/"log").mkpath
4040

4141
# On macOS, create a minimal config that selects the correct backend.

Formula/g/gphotos-uploader-cli.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def install
2323
-s -w
2424
-X github.com/gphotosuploader/gphotos-uploader-cli/version.versionString=#{version}
2525
]
26-
system "go", "build", *std_go_args(ldflags: ldflags)
26+
system "go", "build", *std_go_args(ldflags:)
2727
end
2828

2929
test do

Formula/m/mender-artifact.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def install
3636
end
3737

3838
ldflags = "-s -w -X github.com/mendersoftware/mender-artifact/cli.Version=#{version}"
39-
system "go", "build", *std_go_args(ldflags: ldflags)
39+
system "go", "build", *std_go_args(ldflags:)
4040

4141
# mender-artifact doesn't support autocomplete generation so we have to
4242
# install the individual files instead of using

Formula/p/privatebin-cli.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class PrivatebinCli < Formula
1818

1919
def install
2020
ldflags = "-s -w -X main.version=#{version} -X main.commit=#{tap.user} -X main.date=#{time.iso8601}"
21-
system "go", "build", *std_go_args(ldflags: ldflags, output: bin/"privatebin"), "./cmd/privatebin"
21+
system "go", "build", *std_go_args(ldflags:, output: bin/"privatebin"), "./cmd/privatebin"
2222
end
2323

2424
test do

Formula/t/terraform-ls.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def install
2727
-s -w
2828
-X main.rawVersion=#{version}+#{tap.user}
2929
]
30-
system "go", "build", *std_go_args(ldflags: ldflags.join(" "))
30+
system "go", "build", *std_go_args(ldflags:)
3131
end
3232

3333
test do

Formula/t/tofu-ls.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def install
2727
-s -w
2828
-X main.rawVersion=#{version}+#{tap.user}
2929
]
30-
system "go", "build", *std_go_args(ldflags: ldflags.join(" "))
30+
system "go", "build", *std_go_args(ldflags:)
3131
end
3232

3333
test do

0 commit comments

Comments
 (0)