Skip to content

Concarency atomic

Concarency atomic #55

Workflow file for this run

name: Build and Test
on:
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: '1.24'
- name: Generate version
id: version
run: |
chmod +x scripts/version.sh
VERSION=$(./scripts/version.sh)
echo "version=${VERSION}" >> $GITHUB_OUTPUT
echo "Generated version: ${VERSION}"
- name: Clone gh-pages content
run: |
rm -rf app/desktop/content
git clone --branch gh-pages --single-branch --depth 1 https://github.com/GoFarsi/book.git app/desktop/content
- name: Build
run: |
cd app/desktop
go build -ldflags "-X main.VERSION=${{ steps.version.outputs.version }}" -o ../../build/book .