Skip to content

Create GitHub release #260

Create GitHub release

Create GitHub release #260

Workflow file for this run

name: Create GitHub release
on:
workflow_dispatch:
inputs:
release:
type: choice
description: 'Should this build be released?'
options:
- true
- false
default: 'false'
ref_to_build:
description: 'Ref to build (only tested by providing tags), e.g. v6.1.0'
required: true
env:
SIGNAL_TAG: ${{ inputs.ref_to_build }}
jobs:
linux:
runs-on: ubuntu-22.04-arm
steps:
# Checkout repos
- name: Get GH token
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GH_APP_DENNIS_APP_ID }}
private_key: ${{ secrets.GH_APP_DENNIS_PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
repository: 'signalapp/signal-desktop'
ref: ${{ inputs.ref_to_build }}
token: ${{ steps.generate_token.outputs.token }}
fetch-depth: 200
- name: Create ${{ inputs.ref_to_build }} tag in dennisameling/Signal-Desktop
run: |
git remote add dennis https://github.com/dennisameling/Signal-Desktop
git push --force dennis HEAD:refs/tags/$SIGNAL_TAG
- uses: actions/checkout@v4
with:
path: ./tmp-automation-release-scripts
# Install NodeJS and prepare dependencies
- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4
- name: Setup node.js
uses: actions/setup-node@cdca7365b2dadb8aad0a33bc7601856ffabcc48e # v4
with:
node-version-file: '.nvmrc'
cache: 'pnpm'
cache-dependency-path: 'pnpm-lock.yaml'
- run: sudo apt-get update && sudo apt-get install xvfb libpulse0
- run: npm install -g npm@10.2.5
- uses: ruby/setup-ruby@v1
with:
ruby-version: '3.3'
- name: Install FPM (for packaging)
run: gem install fpm
- name: Prepare release signing
run: |
echo ${{ secrets.SIGN_RELEASE_PUBLIC_KEY }} >> public.key
echo ${{ secrets.SIGN_RELEASE_PRIVATE_KEY }} >> private.key
# Copy files to the patches/ directory where all of Signal's per-dependency patches live
# NOTE: after creating a patch, make sure to add it to patch-files.mjs too!
- run: cp -v ./tmp-automation-release-scripts/patches/* patches/
# The script below ensures that we overwrite some defaults from the official Signal repo
- name: Overwrite updates server, public key, etc.
run: PUBLIC_KEY="${{ secrets.SIGN_RELEASE_PUBLIC_KEY }}" SIGNAL_DIR="${{ github.workspace }}" node ./tmp-automation-release-scripts/patch-files.mjs
# Build Sticker Creator
- working-directory: ./sticker-creator
run: |
pnpm install
pnpm run build
# The steps below pretty much exactly mimic the official build
# https://github.com/signalapp/Signal-Desktop/blob/main/.github/workflows/ci.yml
# Note that we use --no-frozen-lockfile here because we added an entry to
# the pnpm.patchedDependencies section in package.json (see patch-files.mjs)
- run: pnpm install --no-frozen-lockfile
- run: pnpm run generate
- run: pnpm run prepare-beta-build
- name: Create bundle
run: pnpm run build:esbuild:prod
# Doesn't seem to work and no logs, so skipping it
#- name: Create preload cache
# run: xvfb-run --auto-servernum pnpm run build:preload-cache
# env:
# ARTIFACTS_DIR: artifacts/linux
- name: Build with packaging .deb file
run: pnpm run build:release --publish=never
env:
USE_SYSTEM_FPM: 'true'
DISABLE_INSPECT_FUSE: 'on'
- run: xvfb-run --auto-servernum pnpm run test-node
- run: xvfb-run --auto-servernum pnpm run test-electron
- uses: actions/upload-artifact@v4
with:
name: release-binaries
path: release/signal-desktop-unofficial*
release:
needs: linux
runs-on: ubuntu-latest
if: inputs.release == 'true'
outputs:
release_url: ${{ steps.release-url.outputs.html_url }}
signal_version: ${{ steps.signal-version.outputs.version }}
steps:
- name: Get GH token
id: generate_token
uses: tibdex/github-app-token@v2
with:
app_id: ${{ secrets.GH_APP_DENNIS_APP_ID }}
private_key: ${{ secrets.GH_APP_DENNIS_PRIVATE_KEY }}
# Turns v6.1.0 into 6.1.0
- name: Get version from tag
id: signal-version
run: |
SIGNAL_VERSION=${SIGNAL_TAG#"v"}
echo "SIGNAL_VERSION=${SIGNAL_VERSION}" >> $GITHUB_ENV
echo "SIGNAL_TAG=${SIGNAL_TAG}" >> $GITHUB_ENV
echo "version=${SIGNAL_VERSION}" >> $GITHUB_OUTPUT
- uses: actions/download-artifact@v4
with:
name: release-binaries
path: binaries
- uses: ncipollo/release-action@v1
id: release-url
with:
owner: dennisameling
repo: Signal-Desktop
makeLatest: true
artifacts: 'binaries/*'
tag: ${{ inputs.ref_to_build }}
body: |
This is the v${{ env.SIGNAL_VERSION }} release.
## Linux arm64
This release contains a `.deb` file for Linux users. Note that auto-updates are **not** supported on this platform.
## Windows arm64
> [!WARNING]
> Official support for Windows arm64 [was added in Signal 7.34.0](https://github.com/signalapp/Signal-Desktop/issues/3745#issuecomment-2489355026), meaning that I will no longer be offering builds for Signal Unofficial. The last release with Windows arm64 support here is 7.35.0. **You can migrate to the official client while keeping all your chat history and data**. Instructions are [here](https://github.com/dennisameling/Signal-Desktop/issues/24#issuecomment-2490816224).
name: v${{ env.SIGNAL_VERSION }}
token: ${{ steps.generate_token.outputs.token }}