From 36d5e92b986e64f721706850a752e182f62fb16d Mon Sep 17 00:00:00 2001 From: trivernis Date: Mon, 14 Feb 2022 17:49:32 +0100 Subject: [PATCH] Add python based build to build workflow Signed-off-by: trivernis --- .github/workflows/build.yml | 39 +++++++++++++------------------------ 1 file changed, 13 insertions(+), 26 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index eb2cce2..7a29a7f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -64,11 +64,6 @@ jobs: # to run fewer steps in parallel needs: build-api - defaults: - run: - shell: bash - working-directory: mediarepo-daemon - strategy: fail-fast: false matrix: @@ -90,8 +85,13 @@ jobs: restore-keys: | ${{ runner.os }}-cargo- + - name: setup python + uses: actions/setup-python@v2 + with: + python-version: '^3.7' + - name: Build - run: cargo build --release --no-default-features --verbose + run: python build.py build --daemon --verbose - name: Upload artifacts if: ${{ !env.ACT }} @@ -99,18 +99,13 @@ jobs: with: name: mediarepo-daemon-${{ runner.os }} path: | - target/release/mediarepo-daemon* + out/* build-ui: # to run fewer steps in parallel needs: build-api - defaults: - run: - shell: bash - working-directory: mediarepo-ui - runs-on: ${{ matrix.os }} strategy: @@ -142,17 +137,10 @@ jobs: with: node-version: 16 - - name: Install Tauri - run: cargo install tauri-cli --git https://github.com/tauri-apps/tauri - - - name: Install Angular CLI - run: npm install -g @angular/cli - - - name: Install yarn - run: npm install -g yarn - - - name: Install dependencies - run: yarn install + - name: setup python + uses: actions/setup-python@v2 + with: + python-version: '^3.7' - name: Install OS-specific dependencies uses: knicknic/os-specific-run@v1.0.3 @@ -162,7 +150,7 @@ jobs: DEBIAN_FRONTEND=noninteractive sudo apt-get install libwebkit2gtk-4.0-dev libgtk-3-dev libappindicator3-dev -y - name: Build project - run: cargo tauri build --verbose + run: python build.py build --ui --verbose - name: Upload artifacts if: ${{ !env.ACT }} @@ -170,5 +158,4 @@ jobs: with: name: mediarepo-ui-${{ runner.os }}-release path: | - src-tauri/target/release/bundle - src-tauri/target/release/mediarepo-ui* + out/*