chore: update version to 1.3.4 #9
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| on: | |
| push: | |
| tags: ["v*"] | |
| permissions: | |
| contents: write | |
| jobs: | |
| check-version: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Verify tag matches CMake project version | |
| run: | | |
| tag_version="${GITHUB_REF_NAME#v}" | |
| cmake_version="$(sed -nE 's/^project\(obs-irl-source VERSION ([0-9]+\.[0-9]+\.[0-9]+).*/\1/p' CMakeLists.txt)" | |
| echo "tag: ${tag_version} CMakeLists.txt: ${cmake_version}" | |
| if [ "${tag_version}" != "${cmake_version}" ]; then | |
| echo "::error::Tag ${GITHUB_REF_NAME} does not match project(VERSION ${cmake_version}) in CMakeLists.txt. Bump the version, commit, then re-tag." | |
| exit 1 | |
| fi | |
| build: | |
| needs: check-version | |
| uses: ./.github/workflows/build.yml | |
| release: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| steps: | |
| # The changelog is built from the commit range since the previous tag, | |
| # so the job needs full history and every tag, not the default shallow | |
| # single-commit checkout. | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| path: artifacts | |
| # Package layouts mirror where each platform expects plugins, so a | |
| # release archive is extracted straight into place with no renaming. | |
| # One archive per platform: the plugin bundles its own FFmpeg, so there | |
| # is no longer a per-OBS-line artifact to disambiguate. | |
| - name: Package | |
| run: | | |
| set -euo pipefail | |
| version="${GITHUB_REF_NAME#v}" | |
| mkdir -p dist | |
| # Linux: extract into ~/.config/obs-studio/plugins/ | |
| staging="$(mktemp -d)" | |
| mkdir -p "${staging}/obs-irl-source/bin/64bit" | |
| cp artifacts/obs-irl-source-linux-x64/obs-irl-source.so \ | |
| "${staging}/obs-irl-source/bin/64bit/" | |
| tar -C "${staging}" -czf "dist/obs-irl-source-${version}-linux-x64.tar.gz" obs-irl-source | |
| rm -rf "${staging}" | |
| # Windows: extract into the OBS Studio install folder | |
| # (the DLLs land in obs-plugins\64bit) | |
| staging="$(mktemp -d)" | |
| mkdir -p "${staging}/obs-plugins/64bit" | |
| cp artifacts/obs-irl-source-windows-x64/*.dll "${staging}/obs-plugins/64bit/" | |
| (cd "${staging}" && zip -r \ | |
| "${GITHUB_WORKSPACE}/dist/obs-irl-source-${version}-windows-x64.zip" \ | |
| obs-plugins) | |
| rm -rf "${staging}" | |
| # macOS: extract into ~/Library/Application Support/obs-studio/plugins/. | |
| # OBS on macOS only scans .plugin bundles — its module path is | |
| # %module%.plugin/Contents/MacOS with an extensionless binary — so | |
| # this must be a bundle, not the Linux-style bin/ directory. | |
| staging="$(mktemp -d)" | |
| mkdir -p "${staging}/obs-irl-source.plugin/Contents/MacOS" | |
| cp artifacts/obs-irl-source-macos-arm64/obs-irl-source.so \ | |
| "${staging}/obs-irl-source.plugin/Contents/MacOS/obs-irl-source" | |
| sed "s/@PLUGIN_VERSION@/${version}/g" cmake/macos/Info.plist.in \ | |
| > "${staging}/obs-irl-source.plugin/Contents/Info.plist" | |
| (cd "${staging}" && zip -r \ | |
| "${GITHUB_WORKSPACE}/dist/obs-irl-source-${version}-macos-arm64.zip" \ | |
| obs-irl-source.plugin) | |
| rm -rf "${staging}" | |
| (cd dist && sha256sum ./* > sha256sums.txt) | |
| ls -l dist | |
| # Grouped by conventional commit type, so the draft already reads as a | |
| # changelog instead of needing one written by hand before publishing. | |
| - name: Build changelog | |
| run: | | |
| set -euo pipefail | |
| { | |
| cat .github/release-notes-header.md | |
| echo "## What's changed" | |
| echo | |
| scripts/changelog.sh "${GITHUB_REF_NAME}" | |
| } > notes.md | |
| cat notes.md | |
| - name: Create draft release | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: | | |
| set -euo pipefail | |
| version="${GITHUB_REF_NAME#v}" | |
| gh release create "${GITHUB_REF_NAME}" dist/* \ | |
| --draft \ | |
| --title "obs-irl-source ${version}" \ | |
| --notes-file notes.md |