From a34e682fa8ac0bdc31b5f187ad28c12f60c15454 Mon Sep 17 00:00:00 2001 From: Drew Galbraith Date: Wed, 24 Sep 2025 01:36:12 -0700 Subject: [PATCH 1/2] Forgejo Action: Run just check. --- .forgejo/workflows/ci.yml | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 .forgejo/workflows/ci.yml diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml new file mode 100644 index 0000000..581ea75 --- /dev/null +++ b/.forgejo/workflows/ci.yml @@ -0,0 +1,38 @@ +name: CI + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + check: + runs-on: docker + + steps: + - uses: actions/checkout@v4 + + - name: Install Rust + uses: https://github.com/dtolnay/rust-toolchain@stable + with: + toolchain: stable + components: "clippy, rustfmt" + - name: Rust Cache + uses: https://github.com/Swatinem/rust-cache@v2 + + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' + cache-dependency-path: 'frontend/package-lock.json' + + - name: Install frontend dependencies + run: | + cd frontend + npm ci + + - run: apt install just clang + - name: Run just check + run: just check From 79f8448b2078b5cefbe7756e136c5cec5dd64d64 Mon Sep 17 00:00:00 2001 From: Drew Galbraith Date: Wed, 24 Sep 2025 01:36:12 -0700 Subject: [PATCH 2/2] Forgejo Action: Run just check. --- .forgejo/workflows/ci.yml | 57 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 .forgejo/workflows/ci.yml diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml new file mode 100644 index 0000000..614f29f --- /dev/null +++ b/.forgejo/workflows/ci.yml @@ -0,0 +1,57 @@ +name: CI + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + check-backend: + runs-on: docker + container: + image: rust:1.90 + + steps: + - uses: actions/checkout@v4 + - name: "Check Format" + run: cargo fmt --check + working-directory: backend + - name: "Lint" + run: | + rustup component add clippy + cargo clippy + working-directory: backend + - name: "Unit Tests" + run: cargo test -- --skip api + working-directory: backend + - name: "Integration Tests" + run: cargo test --test api + working-directory: backend + + check-frontend: + runs-on: docker + steps: + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: '20' + + - name: Install dependencies + run: npm ci + working-directory: frontend + + - name: Check Format + run: "npm run format:check" + working-directory: frontend + + - name: Lint + run: npm run lint + working-directory: frontend + + - name: Typecheck + run: npm run typecheck + + - name: Test + run: npm run test +