Add justfile, ols/odinfmt config, tests and Gitea workflows; drop odin.json
- justfile with build/run/check/test/release/package/fmt/clean recipes - ols.json and odinfmt.json for neovim (ols) - Tests for memory game rules and card animation; memory.deal and memory.select_card split out so logic is testable without a window - Gitea workflows: build+test on main/develop, package and upload to the generic package registry on version branches - Game changes to the executable's directory so packaged builds find assets Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
148570a4e6
commit
9ee2eabe9a
12 files changed
+428
-23
No files matched your search
@@ -0,0 +1,53 @@
|
||||
#
|
||||
# .gitea/workflows/gitea-build.yaml
|
||||
#
|
||||
# Builds and tests on every push and pull request to main and develop.
|
||||
#
|
||||
|
||||
name: "Build and Test"
|
||||
on:
|
||||
push:
|
||||
branches: [main, develop]
|
||||
pull_request:
|
||||
branches: [main, develop]
|
||||
|
||||
env:
|
||||
ODIN_VERSION: dev-2026-09
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install System Dependencies
|
||||
run: |
|
||||
SUDO=""; command -v sudo >/dev/null && SUDO=sudo
|
||||
$SUDO apt-get update
|
||||
# clang links Odin programs; raylib needs X11 on Linux
|
||||
$SUDO apt-get install -y --no-install-recommends clang libx11-dev curl ca-certificates
|
||||
|
||||
- name: Install Odin
|
||||
run: |
|
||||
curl -fsSL -o odin.tar.gz https://github.com/odin-lang/Odin/releases/download/$ODIN_VERSION/odin-linux-amd64-$ODIN_VERSION.tar.gz
|
||||
mkdir -p "$HOME/odin"
|
||||
tar -xzf odin.tar.gz -C "$HOME/odin" --strip-components=1
|
||||
echo "$HOME/odin" >> "$GITHUB_PATH"
|
||||
|
||||
- name: Install just
|
||||
run: |
|
||||
mkdir -p "$HOME/.local/bin"
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://just.systems/install.sh | bash -s -- --to "$HOME/.local/bin"
|
||||
echo "$HOME/.local/bin" >> "$GITHUB_PATH"
|
||||
|
||||
- name: Check
|
||||
run: |
|
||||
odin version
|
||||
just check
|
||||
|
||||
- name: Test
|
||||
run: just test
|
||||
|
||||
- name: Build
|
||||
run: just release
|
||||
Reference in new issue
Block a user