Skip to content

fix: platform-neutral path math + a couple of other chores #69

fix: platform-neutral path math + a couple of other chores

fix: platform-neutral path math + a couple of other chores #69

Workflow file for this run

name: checks
env:
HOMEBREW_NO_ANALYTICS: '1'
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
concurrency:
group: checks-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
# If your repo has a go.mod, this will pick the version from it.
go-version-file: go.mod
cache: true
- name: Cache Homebrew downloads
id: brew_dl
uses: actions/cache@v4
with:
path: |
~/.cache/Homebrew
key: brew-cache-${{ runner.os }}-${{ hashFiles('Brewfile') }}
restore-keys: |
brew-cache-${{ runner.os }}-
- name: Set up Homebrew
uses: Homebrew/actions/setup-homebrew@main
- name: Detect Homebrew prefix
id: brew
run: echo "prefix=$(brew --prefix)" >> "$GITHUB_OUTPUT"
- name: Cache Homebrew installation
id: brew_install
uses: actions/cache@v4
with:
path: |
${{ steps.brew.outputs.prefix }}/Cellar
${{ steps.brew.outputs.prefix }}/opt
${{ steps.brew.outputs.prefix }}/bin
${{ steps.brew.outputs.prefix }}/sbin
${{ steps.brew.outputs.prefix }}/lib
${{ steps.brew.outputs.prefix }}/include
${{ steps.brew.outputs.prefix }}/share
${{ steps.brew.outputs.prefix }}/etc
${{ steps.brew.outputs.prefix }}/var
${{ steps.brew.outputs.prefix }}/Homebrew/Library/Taps
key: brew-install-${{ runner.os }}-${{ hashFiles('Brewfile') }}
restore-keys: |
brew-install-${{ runner.os }}-
- name: Install Homebrew tools (only if cache miss)
if: steps.brew_install.outputs.cache-hit != 'true'
run: brew bundle --no-upgrade --file=Brewfile
- name: Self-install
run: go run bootstrap.go
- name: Parallelism check
run: stave parallelismcheck
- name: Project init
run: stave init
- name: Run tests
run: stave test