diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..ec9e152 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,39 @@ +name: CI +on: + push: + branches: [ main ] + pull_request: + workflow_dispatch: +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up Zig + uses: korandoru/setup-zig@v1 + with: + zig-version: master + - name: Build + run: zig build + + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up Zig + uses: korandoru/setup-zig@v1 + with: + zig-version: master + - name: Lint + run: zig fmt --check src/*.zig + + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up Zig + uses: korandoru/setup-zig@v1 + with: + zig-version: master + - name: Test + run: zig build test \ No newline at end of file