mirror of
https://github.com/tale/headplane.git
synced 2026-08-31 09:18:29 +00:00
chore: simplify ci pipeline
This commit is contained in:
@@ -2,14 +2,12 @@ name: Build
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- ".zed/**"
|
|
||||||
- "assets/**"
|
- "assets/**"
|
||||||
- "docs/**"
|
- "docs/**"
|
||||||
- "CHANGELOG.md"
|
- "CHANGELOG.md"
|
||||||
- "README.md"
|
- "README.md"
|
||||||
branches:
|
branches:
|
||||||
- "main"
|
- "main"
|
||||||
- "next"
|
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
@@ -21,42 +19,35 @@ permissions:
|
|||||||
contents: read # Read access to the repository
|
contents: read # Read access to the repository
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
native:
|
ci:
|
||||||
name: native
|
name: Build and Test
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Check out the repo
|
- name: Check out the repo
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Setup Mise
|
- name: Setup pnpm
|
||||||
uses: jdx/mise-action@v2
|
uses: pnpm/action-setup@v4
|
||||||
|
|
||||||
- name: Set caching paths
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
|
|
||||||
echo "GO_CACHE=$(go env GOCACHE)" >> $GITHUB_ENV
|
|
||||||
echo "GO_MODCACHE=$(go env GOMODCACHE)" >> $GITHUB_ENV
|
|
||||||
|
|
||||||
- uses: actions/cache@v4
|
|
||||||
name: Setup pnpm cache
|
|
||||||
with:
|
with:
|
||||||
path: ${{ env.STORE_PATH }}
|
run_install: false
|
||||||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-pnpm-store-
|
|
||||||
|
|
||||||
- name: Setup Go cache
|
- name: Setup Node.js
|
||||||
uses: actions/cache@v4
|
uses: actions/setup-node@v6
|
||||||
with:
|
with:
|
||||||
path: |
|
node-version-file: package.json
|
||||||
${{ env.GO_CACHE }}
|
cache: pnpm
|
||||||
${{ env.GO_MODCACHE }}
|
|
||||||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.mod', '**/go.sum') }}
|
- name: Setup Go
|
||||||
|
uses: actions/setup-go@v6
|
||||||
|
with:
|
||||||
|
go-version-file: go.mod
|
||||||
|
|
||||||
- name: CI pipeline
|
- name: CI pipeline
|
||||||
run: ./build.sh --skip-pnpm-prune
|
run: ./build.sh --skip-pnpm-prune
|
||||||
|
|
||||||
|
- name: Run tests
|
||||||
|
run: pnpm test
|
||||||
|
|
||||||
nix:
|
nix:
|
||||||
name: nix
|
name: nix
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|||||||
Reference in New Issue
Block a user