Update release.yml
This commit is contained in:
@@ -15,13 +15,19 @@ jobs:
|
|||||||
- name: Generate changelog
|
- name: Generate changelog
|
||||||
run: |
|
run: |
|
||||||
echo -e "$(git log $(git describe --tags --abbrev=0)..HEAD --oneline | awk '{print "- "$0}')" > CHANGELOG.md
|
echo -e "$(git log $(git describe --tags --abbrev=0)..HEAD --oneline | awk '{print "- "$0}')" > CHANGELOG.md
|
||||||
|
- name: install lipo
|
||||||
|
run: |
|
||||||
|
curl -L -o /tmp/lipo https://github.com/konoui/lipo/releases/latest/download/lipo_Linux_amd64
|
||||||
|
chmod +x /tmp/lipo
|
||||||
|
mv /tmp/lipo /usr/local/bin
|
||||||
- name: Build Go binaries
|
- name: Build Go binaries
|
||||||
run: |
|
run: |
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
esport CGO_ENABLED=0
|
export CGO_ENABLED=0
|
||||||
|
|
||||||
|
mkdir -p artifacts
|
||||||
|
|
||||||
mkdir artifacts
|
|
||||||
export GOOS=windows
|
export GOOS=windows
|
||||||
export GOARCH=amd64
|
export GOARCH=amd64
|
||||||
export FILENAME=artifacts/go2rtc_win64.zip
|
export FILENAME=artifacts/go2rtc_win64.zip
|
||||||
@@ -65,13 +71,14 @@ jobs:
|
|||||||
|
|
||||||
export GOOS=darwin
|
export GOOS=darwin
|
||||||
export GOARCH=amd64
|
export GOARCH=amd64
|
||||||
export FILENAME=artifacts/go2rtc_mac_amd64.zip
|
go build -ldflags "-s -w" -trimpath -o go2rtc.amd64
|
||||||
go build -ldflags "-s -w" -trimpath && 7z a -mx9 -sdel "$FILENAME" go2rtc
|
|
||||||
|
|
||||||
export GOOS=darwin
|
export GOOS=darwin
|
||||||
export GOARCH=arm64
|
export GOARCH=arm64
|
||||||
export FILENAME=artifacts/go2rtc_mac_arm64.zip
|
go build -ldflags "-s -w" -trimpath -o go2rtc.arm64
|
||||||
go build -ldflags "-s -w" -trimpath && 7z a -mx9 -sdel "$FILENAME" go2rtc
|
|
||||||
|
export FILENAME=artifacts/go2rtc_mac_universal.zip
|
||||||
|
lipo -output go2rtc -create go2rtc.arm64 go2rtc.amd64 && 7z a -mx9 -sdel "$FILENAME" go2rtc
|
||||||
|
|
||||||
parallel --jobs $(nproc) "upx {}" ::: artifacts/go2rtc_linux_*
|
parallel --jobs $(nproc) "upx {}" ::: artifacts/go2rtc_linux_*
|
||||||
- name: Setup tmate session
|
- name: Setup tmate session
|
||||||
|
|||||||
Reference in New Issue
Block a user