diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4eb6b01d..3da54296 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,10 +11,9 @@ on: type: choice options: - all - - macos:x64 - - macos:arm64 - - linux:x64 - - windows:x64 + - macos:all (amd64, arm64) + - linux:all (amd64, arm64) + - windows:all (amd64) environment: description: Environment to run build diff --git a/.github/workflows/pipeline-build-linux.yml b/.github/workflows/pipeline-build-linux.yml index a3e79f84..171631f1 100644 --- a/.github/workflows/pipeline-build-linux.yml +++ b/.github/workflows/pipeline-build-linux.yml @@ -47,9 +47,6 @@ jobs: - name: Install dependencies for root package.js run: yarn install --frozen-lockfile - - name: Download backend - uses: ./.github/actions/download-backend - - name: Configure Environment Variables run: | { @@ -66,27 +63,46 @@ jobs: echo "RI_APP_TYPE=${{ env.RI_APP_TYPE }}" } >> "${{ env.envFile }}" - - name: Build linux package (production) + - name: Download backend x64 + uses: ./.github/actions/download-backend + + - name: Build linux package x64 (production) + if: inputs.environment == 'production' + run: | + yarn package:prod --target linux-x64 --out ${packagePath}-x64.vsix + + - name: Build linux package x64 (staging) + if: inputs.environment == 'staging' + run: | + sed -i "s/^RI_APP_FOLDER_NAME=.*/RI_APP_FOLDER_NAME='.redis-for-vscode-stage'/" ${{ env.envFile }} + yarn package:stage --target linux-x64 --out ${packagePath}-x64.vsix + + - name: Download backend arm64 + uses: ./.github/actions/download-backend + with: + arch: arm64 + + - name: Build linux package arm64 (production) if: inputs.environment == 'production' run: | - yarn package:prod --target linux-x64 --out ${packagePath} + yarn package:prod --target linux-arm64 --out ${packagePath}-arm64.vsix - - name: Build linux package (staging) + - name: Build linux package arm64 (staging) if: inputs.environment == 'staging' run: | sed -i "s/^RI_APP_FOLDER_NAME=.*/RI_APP_FOLDER_NAME='.redis-for-vscode-stage'/" ${{ env.envFile }} - yarn package:stage --target linux-x64 --out ${packagePath} + yarn package:stage --target linux-arm64 --out ${packagePath}-arm64.vsix - uses: actions/upload-artifact@v4 name: Upload extension artifact with: - name: linux-build + name: linux-builds path: | release/redis-for-*.vsix env: envFile: '.env' - packagePath: './release/redis-for-vscode-extension-linux-x64.vsix' + packagePath: './release/redis-for-vscode-extension-linux' RI_SEGMENT_WRITE_KEY: ${{ secrets.RI_SEGMENT_WRITE_KEY }} RI_CLOUD_IDP_AUTHORIZE_URL: ${{ secrets.RI_CLOUD_IDP_AUTHORIZE_URL }} RI_CLOUD_IDP_TOKEN_URL: ${{ secrets.RI_CLOUD_IDP_TOKEN_URL }}