ci: run workflow on ci-artifacts branch pushes #7
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [master, ci-artifacts] | |
| pull_request: | |
| branches: [master] | |
| jobs: | |
| build: | |
| runs-on: ntnu-runners | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Build xz from source | |
| run: | | |
| wget -q https://github.com/tukaani-project/xz/releases/download/v5.8.3/xz-5.8.3.tar.gz | |
| tar xf xz-5.8.3.tar.gz | |
| cd xz-5.8.3 | |
| ./configure --prefix=$HOME/.local | |
| make -j$(nproc) | |
| make install | |
| echo "$HOME/.local/bin" >> $GITHUB_PATH | |
| - name: Install Zig | |
| run: | | |
| wget -q https://ziglang.org/download/0.16.0/zig-linux-x86_64-0.16.0.tar.xz | |
| unxz zig-linux-x86_64-0.16.0.tar.xz | |
| tar xf zig-linux-x86_64-0.16.0.tar | |
| mv zig-linux-x86_64-0.16.0 $HOME/.local/zig | |
| echo "$HOME/.local/zig" >> $GITHUB_PATH | |
| - run: cd crdt-lib && zig build | |
| - run: cd crdt-lib && zig build test | |
| - run: cd crdt-server && zig build | |
| - run: cd crdt-server && zig build test | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: crdt-server | |
| path: | | |
| crdt-server/zig-out/bin/crdt-server* | |
| if-no-files-found: error |