Update go.yml #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Go | |
on: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: '^1.20' | |
- name: Build RSRC | |
run: go install github.com/akavel/rsrc@latest | |
- name: Serverbrowser - Generate rsrc | |
working-directory: ./serverbrowser | |
run: rsrc -ico app.ico -manifest app.manifest -o rsrc.syso | |
- name: Serverbrowser - Get dependencies | |
working-directory: ./serverbrowser | |
run: go get -v -d | |
- name: Serverbrowser - Build Exe | |
working-directory: ./serverbrowser | |
run: go build -trimpath -tags walk_use_cgo -ldflags="-H windowsgui -s -w" | |
- name: Serverstats - Generate rsrc | |
working-directory: ./serverstats | |
run: rsrc -ico app.ico -manifest app.manifest -o rsrc.syso | |
- name: Serverstats - Get dependencies | |
working-directory: ./serverstats | |
run: go get -v -d | |
- name: Serverstats - Build Exe | |
working-directory: ./serverstats | |
run: go build -trimpath -tags walk_use_cgo -ldflags="-H windowsgui -s -w" | |
- name: Serverbrowser - Create sample serverbrowser.json | |
working-directory: ./serverbrowser | |
run: '"{key:""STEAMKEYHERE"", defaultGame:""RS2""}" > serverbrowser.json' | |
- name: Serverbrowser - Add to rs2bundle.zip | |
working-directory: ./serverbrowser | |
run: 7z a -mx9 ../rs2bundle.zip serverbrowser.exe flags.csv flags.png IP2LOCATION-LITE-DB1.BIN serverbrowser.json | |
- name: Serverstats - Add to rs2bundle.zip | |
working-directory: ./serverstats | |
run: 7z a -mx9 ../rs2bundle.zip serverstats.exe | |
- name: Upload rs2bundle.zip | |
uses: actions/[email protected] | |
with: | |
name: rs2bundle.zip | |
path: ./rs2bundle.zip |