From 8ad6631b589e6db41fc57ce801f42ba62b8a407d Mon Sep 17 00:00:00 2001 From: Oleksii Nazarenko Date: Tue, 23 Jul 2024 23:45:50 +0100 Subject: [PATCH] update action to support firefox build --- .github/workflows/ci.yml | 43 ++++++++++++++++++++++++++++++++++------ 1 file changed, 37 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 61f69fe..e242cd5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,11 +1,11 @@ -name: Build and Zip Extension +name: Build and Zip Extensions on: workflow_dispatch: jobs: - build: - name: Build + build-chromium: + name: Build Chromium Extension timeout-minutes: 15 runs-on: ubuntu-latest @@ -27,10 +27,41 @@ jobs: run: bun run build - name: Zip the build contents - run: cd dist && zip -r ../better-studres.zip ./* + run: zip -r better-studres-chromium.zip dist/* - name: Upload extension artifacts uses: actions/upload-artifact@v4 with: - name: better-studres - path: better-studres.zip + name: better-studres-chromium + path: better-studres-chromium.zip + + build-firefox: + name: Build Firefox Extension + timeout-minutes: 15 + runs-on: ubuntu-latest + + steps: + - name: Check out code + uses: actions/checkout@v4 + with: + fetch-depth: 2 + + - name: Setup Bun environment + uses: oven-sh/setup-bun@v1 + with: + bun-version: 0.7.0 + + - name: Install dependencies + run: bun install + + - name: Build + run: bun run build:firefox + + - name: Zip the build contents + run: zip -r better-studres-firefox.zip dist/* + + - name: Upload extension artifacts + uses: actions/upload-artifact@v4 + with: + name: better-studres-firefox + path: better-studres-firefox.zip