Skip to content

Release 2.0.30

Release 2.0.30 #132

Workflow file for this run

name: Package and Release
on:
push:
tags:
- v*
jobs:
test:
name: Lint and Test
runs-on: ubuntu-22.04
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
- run: pnpm install
- name: Lint JS
run: pnpm lint:js
- name: Lint HBS
run: pnpm lint:hbs
- name: Get xvfb
run: sudo apt-get install xvfb
- name: Browser Test
run: pnpm test:ember
- name: Electron Test
run: xvfb-run --auto-servernum pnpm test:electron
build:
name: Build (${{ matrix.os }})
if: startsWith(github.ref, 'refs/tags/')
needs: test
runs-on: ${{ matrix.os }}
timeout-minutes: 30
strategy:
matrix:
os: [macos-15-intel, ubuntu-22.04]
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: 'pnpm'
- run: pnpm install
- name: Add macOS certs
if: startsWith(matrix.os, 'macos') && startsWith(github.ref, 'refs/tags/')
run: chmod +x add-osx-cert.sh && ./add-osx-cert.sh
env:
CERTIFICATE_OSX_APPLICATION: ${{ secrets.CERTIFICATE_OSX_APPLICATION }}
CERTIFICATE_PASSWORD: ${{ secrets.CERTIFICATE_PASSWORD }}
# - name: Add Windows certificate
# if: matrix.os == 'windows-latest' && startsWith(github.ref, 'refs/tags/')
# id: write_file
# uses: timheuer/base64-to-file@v1
# with:
# fileName: 'win-certificate.pfx'
# encodedString: ${{ secrets.CERTIFICATE_WINDOWS_PFX }}
- name: Setup LXD
if: matrix.os == 'ubuntu-22.04' && startsWith(github.ref, 'refs/tags/')
uses: canonical/setup-lxd@v0.1.3
- name: Setup Snapcraft for Publishing
if: matrix.os == 'ubuntu-22.04' && startsWith(github.ref, 'refs/tags/')
run: |
sudo snap install snapcraft --classic
echo "/snap/bin" >> $GITHUB_PATH
- name: Make
if: startsWith(github.ref, 'refs/tags/')
run: pnpm make
env:
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
# WINDOWS_PFX_FILE: ${{ steps.write_file.outputs.filePath }}
# WINDOWS_PFX_PASSWORD: ${{ secrets.WINDOWS_PFX_PASSWORD }}
- name: List files in out directory
if: matrix.os == 'ubuntu-22.04' && startsWith(github.ref, 'refs/tags/')
run: |
echo "Contents of out directory:"
ls -la out/
echo "Looking for snap files:"
find out/ -name "*.snap" -o -name "*snap*" | head -10
- name: Publish Snap to Snap Store
if: matrix.os == 'ubuntu-22.04' && startsWith(github.ref, 'refs/tags/')
run: snapcraft upload $(find out/make/snap/x64/ -name "swach_*_amd64.snap") --release latest/stable
env:
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_TOKEN }}
# - name: Make Apple arm64
# if: matrix.os == 'macos-11.0' && startsWith(github.ref, 'refs/tags/')
# run: pnpm make --arch=arm64
# env:
# APPLE_ID: ${{ secrets.APPLE_ID }}
# APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD_ARM }}
- name: GitHub release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: |
out/**/*.deb
out/**/*.dmg
out/**/*Setup.exe
out/**/*.rpm
out/**/*.zip
- name: Create a Sentry.io release
uses: tclindner/sentry-releases-action@v1.3.0
if: matrix.os == 'ubuntu-22.04'
env:
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
SENTRY_ORG: ship-shape-consulting-llc
SENTRY_PROJECT: swach
with:
tagName: ${{ github.ref }}
environment: production
sourceMapOptions: '{"include": ["dist/assets"], "urlPrefix": "~/dist/assets"}'