Skip to content

Add general chat API #14

Add general chat API

Add general chat API #14

Workflow file for this run

name: Go
on:
push:
branches:
- main
tags:
- v*
pull_request:
branches:
- main
jobs:
build-windows:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: "true"
- name: Setup Golang
uses: actions/setup-go@v4
with:
go-version: '1.21'
- name: Setup build environment
run: sudo apt-get update && sudo apt-get install -y --no-install-recommends --no-install-suggests gcc-mingw-w64-x86-64
- name: Build
run: GOOS=windows CGO_ENABLED=1 CC=x86_64-w64-mingw32-gcc-win32 go build -o ./build/lanty-server.exe -v ./cmd
- name: Package
run: |
cp ./settings.yaml ./build
mkdir ./build/game-config ./build/game-icon ./build/game-data ./build/download
touch ./build/game-config/.keep-me ./build/game-icon/.keep-me ./build/game-data/.keep-me ./build/download/.keep-me
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: lanty-server
path: ./build
if-no-files-found: error
retention-days: 1
overwrite: "true"
release:
if: github.ref_type == 'tag'
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: Download artifact
uses: actions/download-artifact@v4
- name: Zip artifact
uses: vimtor/[email protected]
with:
files: ./lanty-server
dest: lanty-server.zip
- name: Create Release
if:
uses: softprops/action-gh-release@v1
with:
files: |
lanty-server.zip
generate_release_notes: true
needs: build-windows