Skip to content

UPDATE 0.1.0 : FIX CI #12

UPDATE 0.1.0 : FIX CI

UPDATE 0.1.0 : FIX CI #12

Workflow file for this run

name: Build & Release
on:
push:
tags:
- 'v*'
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '1.21'
- name: Build Linux
run: GOOS=linux GOARCH=amd64 go build -o freedom-core-linux-x64 ./cmd/server
- uses: actions/upload-artifact@v4
with:
name: freedom-core-linux-x64
path: freedom-core-linux-x64
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '1.21'
- name: Build Windows
shell: pwsh
run: |
$env:GOOS="windows"
$env:GOARCH="amd64"
go build -o freedom-core-windows-x64.exe ./cmd/server
- uses: actions/upload-artifact@v4
with:
name: freedom-core-windows-x64.exe
path: freedom-core-windows-x64.exe
release:
needs: [build-linux, build-windows]
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/download-artifact@v4
with:
name: freedom-core-linux-x64
path: artifacts
- uses: actions/download-artifact@v4
with:
name: freedom-core-windows-x64.exe
path: artifacts
- name: Upload Executables to Release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ github.ref_name }}
name: ${{ github.ref_name }}
files: artifacts/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}