Skip to content

Commit fb705a8

Browse files
committed
Upd: Change the release file form
1 parent bc333ce commit fb705a8

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

Makefile

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,16 @@ multi: tidy
4545
os=$(shell echo "$(n)" | cut -d : -f 1);\
4646
arch=$(shell echo "$(n)" | cut -d : -f 2);\
4747
target_suffix=$(BINARY_VERSION)-$${os}-$${arch};\
48+
bin_name="tryssh";\
49+
if [ $${os} = "windows" ]; then bin_name="tryssh.exe"; fi;\
4850
echo "[==> Build $${os}-$${arch} start... <==]";\
51+
mkdir -p ./release/$${os}-$${arch};\
52+
cp ./LICENSE ./release/$${os}-$${arch}/;\
4953
env CGO_ENABLED=0 GOOS=$${os} GOARCH=$${arch} go build -v -trimpath -ldflags "$(LDFLAGS)" \
50-
-o ./release/tryssh-$${target_suffix};\
54+
-o ./release/$${os}-$${arch}/$${bin_name};\
55+
cd ./release;\
56+
zip -rq tryssh-$${target_suffix}.zip $${os}-$${arch};\
57+
rm -rf $${os}-$${arch};\
58+
cd ..;\
5159
echo "[==> Build $${os}-$${arch} done <==]";\
5260
)
53-
@mv ./release/tryssh-$(BINARY_VERSION)-windows-amd64 ./release/tryssh-$(BINARY_VERSION)-windows-amd64.exe
54-
@mv ./release/tryssh-$(BINARY_VERSION)-windows-arm64 ./release/tryssh-$(BINARY_VERSION)-windows-arm64.exe

0 commit comments

Comments
 (0)