From c701e47812956e952d783924fe8508509f95714d Mon Sep 17 00:00:00 2001 From: falkTX Date: Wed, 8 May 2024 15:33:48 +0200 Subject: [PATCH] Upload build artifacts to CI Signed-off-by: falkTX --- .github/workflows/build.yml | 54 +++++++++++++++++++++++++------------ 1 file changed, 37 insertions(+), 17 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 62baf60..7404b7e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -15,40 +15,52 @@ jobs: strategy: matrix: container: - - debian:12 - - ubuntu:20.04 - - ubuntu:22.04 - - ubuntu:24.04 + - name: debian-12 + target: debian:12 + - name: ubuntu-20.04 + target: ubuntu:20.04 + - name: ubuntu-22.04 + target: ubuntu:22.04 + - name: ubuntu-24.04 + target: ubuntu:24.04 runs-on: ubuntu-latest container: - image: ${{ matrix.container }} + image: ${{ matrix.container.target }} steps: - uses: actions/checkout@v4 - name: Set up dependencies run: | apt-get update -qq apt-get install -yqq g++ libgtk2.0-dev libgtk-3-dev liblilv-dev lv2-dev libx11-dev make pkg-config - - name: Regular build + - name: Run tests (C) env: CFLAGS: -Werror CXXFLAGS: -Werror run: | make clean >/dev/null - make -j $(nproc) - - name: Run tests (C) + make test -j $(nproc) && ./test + - name: Run tests (C++) env: CFLAGS: -Werror CXXFLAGS: -Werror run: | make clean >/dev/null - make test -j $(nproc) && ./test - - name: Run tests (C++) + make testxx -j $(nproc) && ./testxx + - name: Regular build env: CFLAGS: -Werror CXXFLAGS: -Werror run: | make clean >/dev/null - make testxx -j $(nproc) && ./testxx + make -j $(nproc) + - name: Set sha8 + run: | + echo "SHA8=$(echo ${{ github.sha }} | cut -c1-8)" >> $GITHUB_ENV + - uses: actions/upload-artifact@v4 + with: + name: ${{ github.event.repository.name }}-${{ matrix.container.name }}-${{ github.event.pull_request.number || env.SHA8 }} + path: | + *.lv2 macos: strategy: @@ -63,24 +75,32 @@ jobs: - name: Set up dependencies run: | brew install gtk+ gtk+3 lilv make pkg-config - - name: Regular build + - name: Run tests (C) env: CFLAGS: -Werror CXXFLAGS: -Werror run: | make clean >/dev/null - make -j $(sysctl -n hw.logicalcpu) - - name: Run tests (C) + make test -j $(sysctl -n hw.logicalcpu) && ./test + - name: Run tests (C++) env: CFLAGS: -Werror CXXFLAGS: -Werror run: | make clean >/dev/null - make test -j $(sysctl -n hw.logicalcpu) && ./test - - name: Run tests (C++) + make testxx -j $(sysctl -n hw.logicalcpu) && ./testxx + - name: Regular build env: CFLAGS: -Werror CXXFLAGS: -Werror run: | make clean >/dev/null - make testxx -j $(sysctl -n hw.logicalcpu) && ./testxx + make -j $(sysctl -n hw.logicalcpu) + - name: Set sha8 + run: | + echo "SHA8=$(echo ${{ github.sha }} | cut -c1-8)" >> $GITHUB_ENV + - uses: actions/upload-artifact@v4 + with: + name: ${{ github.event.repository.name }}-${{ matrix.target }}-${{ github.event.pull_request.number || env.SHA8 }} + path: | + *.lv2