text/x-yaml
•
4.87 KB
•
182 lines
name: CI
on:
push:
jobs:
build-windows:
name: ${{matrix.os}}-${{ matrix.sys }}
runs-on: ${{ matrix.os }}
defaults:
run:
shell: msys2 {0}
strategy:
fail-fast: false
matrix:
os: [windows-2019, windows-2022]
sys: [mingw64, mingw32, ucrt64, clang64]
steps:
- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.sys }}
install: base-devel
pacboy: toolchain:p
- name: Checkout
uses: actions/checkout@v2
- name: Compile bootstrap runtime
run: make -j2 nujel-bootstrap
- name: Test bootstrap runtime
run: make test.bootstrap
- name: Compile runtime
run: make -j2 nujel.exe
- name: Test runtime
run: make test.slow
release-windows:
name: release-windows-${{ matrix.sys }}
needs: build-windows
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
strategy:
fail-fast: false
matrix:
sys: [mingw32, mingw64, ucrt64, clang64]
steps:
- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.sys }}
install: base-devel
pacboy: toolchain:p
- name: Checkout
uses: actions/checkout@v2
- name: Compile bootstrap runtime
run: make -j2 nujel-bootstrap
- name: Test bootstrap runtime
run: make test.bootstrap
- name: Compile release
run: make -j2 release
- name: Run Tests
run: make test
- name: Upload release
uses: actions/upload-artifact@v2
with:
name: Nujel-windows-${{ matrix.sys }}-${{ github.ref_name }}
path: "./nujel.exe"
retention-days: 7
build-macos:
name: build-${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [macos-12, macos-11, macos-10.15]
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Compile bootstrap runtime
run: make -j2 nujel-bootstrap
- name: Test bootstrap runtime
run: make test.bootstrap
- name: Compile runtime
run: make -j2 nujel
- name: Test runtime
run: make test.slow
release-macos:
needs: build-macos
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Compile bootstrap runtime
run: make -j2 nujel-bootstrap
- name: Test bootstrap runtime
run: make test.bootstrap
- name: Build Release
run: make -j2 release
- name: Test runtime
run: make test
- name: Upload release
uses: actions/upload-artifact@v2
with:
name: Nujel-macos-${{ github.ref_name }}
path: "./nujel"
retention-days: 7
build-linux:
name: ${{ matrix.os }}-${{ matrix.cc }}-${{matrix.make}}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04, ubuntu-20.04, ubuntu-18.04]
cc: [clang, gcc]
make: [make]
include:
- os: ubuntu-20.04
cc: gcc
make: bmake
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install compiler
run: |
sudo apt-get -y install ${{ matrix.cc }} ${{ matrix.make }}
- name: Compile bootstrap runtime
run: ${{matrix.make}} CC=${{ matrix.cc }} -j2 nujel-bootstrap
- name: Test bootstrap runtime
run: ${{matrix.make}} CC=${{ matrix.cc }} test.bootstrap
- name: Compile runtime
run: ${{matrix.make}} CC=${{ matrix.cc }} -j2 nujel
- name: Test runtime
run: ${{matrix.make}} test.slow
static-analysis-linux:
name: clang-static-analyzer
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install compiler
run: |
sudo apt-get -y install clang clang-tools make
- name: Run static analyzer
run: scan-build --status-bugs make nujel-bootstrap
release-linux:
runs-on: ubuntu-latest
needs: build-linux
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Dependencies
run: sudo apt-get install -y musl-dev musl-tools
- name: Build bootstrap runtime
run: make -j2 nujel-bootstrap
- name: Test bootstrap runtime
run: make test.bootstrap
- name: Build release
run: make release.musl
- name: Test runtime
run: make test
- name: Upload release
uses: actions/upload-artifact@v2
with:
name: Nujel-linux-${{ github.ref_name }}
path: "./nujel"
retention-days: 7
release-wasm:
runs-on: ubuntu-latest
needs: build-linux
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Compile
run: make -j2
- name: Compile WASM REPL
run: bash tools/buildwasm
- name: Upload release
uses: actions/upload-artifact@v2
with:
name: Nujel-Web-${{ github.ref_name }}
path: "./web/"
retention-days: 7