summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunegunn Choi <junegunn.c@gmail.com>2024-04-23 17:24:50 +0900
committerJunegunn Choi <junegunn.c@gmail.com>2024-04-23 17:24:50 +0900
commit207deeadba2721435a21e0f68c61e522eedef26c (patch)
tree57119c4cdebb5e496efbd1cc7fa0964b683a1388
parentd18d92f925f791271b095df968d290ced05d065a (diff)
downloadfzf-207deeadba2721435a21e0f68c61e522eedef26c.tar.gz
Add -trimpath to build command
-rw-r--r--.goreleaser.yml6
-rw-r--r--Makefile2
2 files changed, 7 insertions, 1 deletions
diff --git a/.goreleaser.yml b/.goreleaser.yml
index 1ac56108..86e821f0 100644
--- a/.goreleaser.yml
+++ b/.goreleaser.yml
@@ -12,6 +12,8 @@ builds:
- darwin
goarch:
- amd64
+ flags:
+ - -trimpath
ldflags:
- "-s -w -X main.version={{ .Version }} -X main.revision={{ .ShortCommit }}"
hooks:
@@ -36,6 +38,8 @@ builds:
- darwin
goarch:
- arm64
+ flags:
+ - -trimpath
ldflags:
- "-s -w -X main.version={{ .Version }} -X main.revision={{ .ShortCommit }}"
hooks:
@@ -71,6 +75,8 @@ builds:
- 5
- 6
- 7
+ flags:
+ - -trimpath
ldflags:
- "-s -w -X main.version={{ .Version }} -X main.revision={{ .ShortCommit }}"
ignore:
diff --git a/Makefile b/Makefile
index 0416cc35..44b010c5 100644
--- a/Makefile
+++ b/Makefile
@@ -25,7 +25,7 @@ endif
ifeq ($(REVISION),)
$(error Not on git repository; cannot determine $$FZF_REVISION)
endif
-BUILD_FLAGS := -a -ldflags "-s -w -X main.version=$(VERSION) -X main.revision=$(REVISION)" -tags "$(TAGS)"
+BUILD_FLAGS := -a -ldflags "-s -w -X main.version=$(VERSION) -X main.revision=$(REVISION)" -tags "$(TAGS)" -trimpath
BINARY32 := fzf-$(GOOS)_386
BINARY64 := fzf-$(GOOS)_amd64