From 8a3fcd88a210d8ce281471e15a9b517388b6dda6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C5=91rik=20Levente?= <33373714+Levminer@users.noreply.github.com> Date: Sat, 28 Sep 2024 22:51:39 +0200 Subject: [PATCH] create workflow --- .github/workflows/alpha-build.yml | 2 +- .github/workflows/unix-alpha-build.yml | 58 ++++++++++++++++++++++++++ 2 files changed, 59 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/unix-alpha-build.yml diff --git a/.github/workflows/alpha-build.yml b/.github/workflows/alpha-build.yml index c60417f..6abc52b 100644 --- a/.github/workflows/alpha-build.yml +++ b/.github/workflows/alpha-build.yml @@ -1,4 +1,4 @@ -name: Alpha build +name: Alpha Windows build on: push diff --git a/.github/workflows/unix-alpha-build.yml b/.github/workflows/unix-alpha-build.yml new file mode 100644 index 0000000..c4318df --- /dev/null +++ b/.github/workflows/unix-alpha-build.yml @@ -0,0 +1,58 @@ +name: Alpha Unix build + +on: push + +jobs: + build: + strategy: + matrix: + include: + - os: macos-latest + NAME: macos + - os: ubuntu-latest + NAME: linux + + runs-on: ${{ matrix.os}} + + env: + TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }} + SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install cross-rs + run: cargo install cross + + - name: Build service executable + if: matrix.NAME == 'linux' + run: cd platforms/unix/daemon && cargo build --release && cross build --release --target aarch64-unknown-linux-gnu + + - name: Install node modules + run: npm ci + + # Build service installer + - name: Build service installer + run: npm run build:core + + - name: Get version + id: version + uses: notiz-dev/github-action-json-property@release + with: + path: package.json + prop_path: version + + - name: Remove useless folders + run: | + rm -rf target/release/build + rm -rf target/release/deps + rm -rf target/release/bundle/appimage/authme.AppDir + npm run rename + shell: bash + + # Upload the unpackaged app + - name: Upload service installer + uses: actions/upload-artifact@v4 + with: + name: "cores-service-${{matrix.NAME}}-x64-installer" + path: "target/release"