Skip to content

Commit d940a63

Browse files
committed
Fix stripping binaries
1 parent 400911a commit d940a63

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,13 @@ jobs:
6161
else
6262
echo "BIN=ris-${{ matrix.platform }}-${{ matrix.arch }}" >> $GITHUB_ENV
6363
fi
64+
if [ ${{ github.event_name }} = 'release' ]; then
65+
echo "RELEASE=1" >> $GITHUB_ENV
66+
fi
6467
6568
- name: Build
6669
run: make
6770

68-
- name: Strip
69-
if: ${{ github.event_name == 'release' }}
70-
run: strip ${{ env.BIN }}
71-
7271
- name: Upload artifacts
7372
uses: actions/upload-artifact@v4
7473
with:

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ BIN ?= ris
88

99
RISFLAGS ?= -w -X main.Version="$(VERSION)"
1010

11+
ifeq ($(RELEASE),1)
12+
RISFLAGS += -s
13+
endif
14+
1115
$(BIN): ris.go
1216
go build -ldflags "$(RISFLAGS)" -o $@
1317

0 commit comments

Comments
 (0)