Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
3c52b48
Initial plan
Copilot Nov 12, 2025
3768eb0
Update build system from OBS plugin template: workflows, actions, and…
Copilot Nov 12, 2025
bd92ebf
Add gersemi config and remove cmake-format config
Copilot Nov 12, 2025
fe4c9b8
Add .gersemirc to repository and update .gitignore
Copilot Nov 12, 2025
59c6034
Update README to reference new build-ubuntu script
Copilot Nov 12, 2025
4f164e3
Add explicit permissions to check-format workflow jobs for security
Copilot Nov 12, 2025
a6bfc92
Update macOS CMake compiler config to match OBS plugin template
Copilot Nov 12, 2025
205628d
Update OBS Studio and dependencies to version 31.1.1
Copilot Nov 13, 2025
34b3cb1
Update jsoncons and inja submodules to latest versions
Copilot Nov 13, 2025
7a7a060
Fix CMake presets and buildspec for cross-platform builds
Copilot Nov 13, 2025
d29a079
Replace deprecated obs_scene_sceneitem_from_source with obs_scene_fin…
Copilot Nov 13, 2025
147fcc3
Replace deprecated QCheckBox::stateChanged with checkStateChanged
Copilot Nov 13, 2025
40274ff
Use QCheckBox::toggled instead of checkStateChanged for Qt6 compatibi…
Copilot Nov 13, 2025
53fd5fe
Update PugiXML to version 1.15 and change URL_HASH to SHA256
royshil Nov 13, 2025
fe2fc2c
Update CMake configuration files for various components
royshil Nov 13, 2025
bf6e244
Refactor formatting checks in .run-format.zsh and improve code readab…
royshil Nov 13, 2025
2af7d7c
Add debug flag to clang-format run command for enhanced output
royshil Nov 13, 2025
091cc52
Update clang-format action to remove debug flag and adjust Zsh versio…
royshil Nov 13, 2025
2afc6ce
Simplify Ubuntu build configuration by removing strategy matrix
royshil Nov 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 0 additions & 40 deletions .cmake-format.json

This file was deleted.

8 changes: 8 additions & 0 deletions .gersemirc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/BlankSpruce/gersemi/master/gersemi/configuration.schema.json

definitions: []
line_length: 120
indent: 2
list_expansion: favour-inlining
unsafe: false
warn_about_unknown_commands: false
29 changes: 18 additions & 11 deletions .github/actions/build-plugin/action.yaml
Original file line number Diff line number Diff line change
@@ -1,23 +1,27 @@
name: 'Set up and build plugin'
description: 'Builds the plugin for specified architecture and build config'
name: Set up and build plugin
description: Builds the plugin for specified architecture and build config
inputs:
target:
description: 'Target architecture for dependencies'
description: Target architecture for dependencies
required: true
config:
description: 'Build configuration'
description: Build configuration
required: false
default: 'RelWithDebInfo'
default: RelWithDebInfo
codesign:
description: 'Enable codesigning (macOS only)'
description: Enable codesigning (macOS only)
required: false
default: 'false'
codesignIdent:
description: 'Developer ID for application codesigning (macOS only)'
description: Developer ID for application codesigning (macOS only)
required: false
default: '-'
codesignTeam:
description: Team ID for application codesigning (macOS only)
required: false
default: ''
workingDirectory:
description: 'Working directory for packaging'
description: Working directory for packaging
required: false
default: ${{ github.workspace }}
runs:
Expand All @@ -28,6 +32,7 @@ runs:
shell: zsh --no-rcs --errexit --pipefail {0}
working-directory: ${{ inputs.workingDirectory }}
env:
CCACHE_DIR: ${{ inputs.workingDirectory }}/.ccache
CODESIGN_IDENT: ${{ inputs.codesignIdent }}
CODESIGN_TEAM: ${{ inputs.codesignTeam }}
run: |
Expand Down Expand Up @@ -55,16 +60,18 @@ runs:
if: runner.os == 'Linux'
shell: zsh --no-rcs --errexit --pipefail {0}
working-directory: ${{ inputs.workingDirectory }}
env:
CCACHE_DIR: ${{ inputs.workingDirectory }}/.ccache
run: |
: Run Ubuntu Build

local -a build_args=(
--target linux-${{ inputs.target }}
--target ubuntu-${{ inputs.target }}
--config ${{ inputs.config }}
)
if (( ${+RUNNER_DEBUG} )) build_args+=(--debug)

.github/scripts/build-linux ${build_args}
.github/scripts/build-ubuntu ${build_args}

- name: Run Windows Build
if: runner.os == 'Windows'
Expand All @@ -86,7 +93,7 @@ runs:
if: contains(fromJSON('["Linux", "macOS"]'),runner.os)
shell: zsh --no-rcs --errexit --pipefail {0}
env:
CCACHE_CONFIGPATH: ${{ inputs.workingDirectory }}/.ccache.conf
CCACHE_DIR: ${{ inputs.workingDirectory }}/.ccache
run: |
: Create Summary 📊

Expand Down
77 changes: 77 additions & 0 deletions .github/actions/check-changes/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
name: Check For Changed Files
description: Checks for changed files compared to specific git reference and glob expression
inputs:
baseRef:
description: Git reference to check against
required: false
ref:
description: Git reference to check with
required: false
default: HEAD
checkGlob:
description: Glob expression to limit check to specific files
required: false
useFallback:
description: Use fallback compare against prior commit
required: false
default: 'true'
diffFilter:
description: git diff-filter string to use
required: false
default: ''
outputs:
hasChangedFiles:
value: ${{ steps.checks.outputs.hasChangedFiles }}
description: True if specified files were changed in comparison to specified git reference
changedFiles:
value: ${{ steps.checks.outputs.changedFiles }}
description: List of changed files
runs:
using: composite
steps:
- name: Check For Changed Files ✅
shell: bash
id: checks
env:
GIT_BASE_REF: ${{ inputs.baseRef }}
GIT_REF: ${{ inputs.ref }}
GITHUB_EVENT_FORCED: ${{ github.event.forced }}
GITHUB_REF_BEFORE: ${{ github.event.before }}
USE_FALLBACK: ${{ inputs.useFallback }}
DIFF_FILTER: ${{ inputs.diffFilter }}
run: |
: Check for Changed Files ✅
if [[ "${RUNNER_DEBUG}" ]]; then set -x; fi
shopt -s extglob
shopt -s dotglob

if [[ "${GIT_BASE_REF}" ]]; then
if ! git cat-file -e "${GIT_BASE_REF}" &> /dev/null; then
echo "::warning::Provided base reference ${GIT_BASE_REF} is invalid"
if [[ "${USE_FALLBACK}" == 'true' ]]; then
GIT_BASE_REF='HEAD~1'
fi
fi
else
if ! git cat-file -e ${GITHUB_REF_BEFORE} &> /dev/null; then
GITHUB_REF_BEFORE='4b825dc642cb6eb9a060e54bf8d69288fbee4904'
fi

GIT_BASE_REF='HEAD~1'
case "${GITHUB_EVENT_NAME}" in
pull_request) GIT_BASE_REF="origin/${GITHUB_BASE_REF}" ;;
push) if [[ "${GITHUB_EVENT_FORCED}" != 'true' ]]; then GIT_BASE_REF="${GITHUB_REF_BEFORE}"; fi ;;
*) ;;
esac
fi

changes=($(git diff --name-only --diff-filter="${DIFF_FILTER}" ${GIT_BASE_REF} ${GIT_REF} -- ${{ inputs.checkGlob }}))

if (( ${#changes[@]} )); then
file_string="${changes[*]}"
echo "hasChangedFiles=true" >> $GITHUB_OUTPUT
echo "changedFiles=[\"${file_string// /\",\"}\"]" >> $GITHUB_OUTPUT
else
echo "hasChangedFiles=false" >> $GITHUB_OUTPUT
echo "changedFiles=[]" >> GITHUB_OUTPUT
fi
36 changes: 16 additions & 20 deletions .github/actions/package-plugin/action.yaml
Original file line number Diff line number Diff line change
@@ -1,47 +1,47 @@
name: 'Package plugin'
description: 'Packages the plugin for specified architecture and build config.'
name: Package plugin
description: Packages the plugin for specified architecture and build config.
inputs:
target:
description: 'Build target for dependencies'
description: Build target for dependencies
required: true
config:
description: 'Build configuration'
description: Build configuration
required: false
default: 'RelWithDebInfo'
default: RelWithDebInfo
codesign:
description: 'Enable codesigning (macOS only)'
description: Enable codesigning (macOS only)
required: false
default: 'false'
notarize:
description: 'Enable notarization (macOS only)'
description: Enable notarization (macOS only)
required: false
default: 'false'
codesignIdent:
description: 'Developer ID for application codesigning (macOS only)'
description: Developer ID for application codesigning (macOS only)
required: false
default: '-'
installerIdent:
description: 'Developer ID for installer package codesigning (macOS only)'
description: Developer ID for installer package codesigning (macOS only)
required: false
default: ''
codesignTeam:
description: 'Developer team for codesigning (macOS only)'
description: Developer team for codesigning (macOS only)
required: false
default: ''
codesignUser:
description: 'Apple ID username for notarization (macOS only)'
description: Apple ID username for notarization (macOS only)
required: false
default: ''
codesignPass:
description: 'Apple ID password for notarization (macOS only)'
description: Apple ID password for notarization (macOS only)
required: false
default: ''
package:
description: 'Create Windows or macOS installation package'
description: Create Windows or macOS installation package
required: false
default: 'false'
workingDirectory:
description: 'Working directory for packaging'
description: Working directory for packaging
required: false
default: ${{ github.workspace }}
runs:
Expand Down Expand Up @@ -87,14 +87,14 @@ runs:
run: |
: Run Ubuntu Packaging
package_args=(
--target linux-${{ inputs.target }}
--target ubuntu-${{ inputs.target }}
--config ${{ inputs.config }}
)
if (( ${+RUNNER_DEBUG} )) build_args+=(--debug)

if [[ '${{ inputs.package }}' == 'true' ]] package_args+=(--package)

.github/scripts/package-linux ${package_args}
.github/scripts/package-ubuntu ${package_args}

- name: Run Windows Packaging
if: runner.os == 'Windows'
Expand All @@ -110,8 +110,4 @@ runs:
Configuration = '${{ inputs.config }}'
}

if ( '${{ inputs.package }}' -eq 'true' ) {
$PackageArgs += @{BuildInstaller = $true}
}

.github/scripts/Package-Windows.ps1 @PackageArgs
39 changes: 19 additions & 20 deletions .github/actions/run-clang-format/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ inputs:
failCondition:
description: Controls whether failed checks also fail the workflow run
required: false
default: 'never'
default: never
workingDirectory:
description: Working directory for checks
required: false
Expand All @@ -20,42 +20,41 @@ runs:
echo "::notice::run-clang-format action requires a macOS-based or Linux-based runner."
exit 2

- name: Check for Changed Files ✅
uses: ./.github/actions/check-changes
id: checks
with:
checkGlob: "'*.c' '*.h' '*.cpp' '*.hpp' '*.m' '*.mm'"
diffFilter: 'ACM'

- name: Install Dependencies 🛍️
if: runner.os == 'Linux'
if: runner.os == 'Linux' && fromJSON(steps.checks.outputs.hasChangedFiles)
shell: bash
run: |
: Install Dependencies 🛍️
echo ::group::Install Dependencies
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
echo "/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin" >> $GITHUB_PATH
echo "/home/linuxbrew/.linuxbrew/opt/clang-format@17/bin" >> $GITHUB_PATH
echo "/home/linuxbrew/.linuxbrew/opt/clang-format@19/bin" >> $GITHUB_PATH
brew install --quiet zsh
echo ::endgroup::

- name: Run clang-format 🐉
if: fromJSON(steps.checks.outputs.hasChangedFiles)
id: result
shell: zsh --no-rcs --errexit --pipefail {0}
working-directory: ${{ inputs.workingDirectory }}
env:
GITHUB_EVENT_FORCED: ${{ github.event.forced }}
GITHUB_REF_BEFORE: ${{ github.event.before }}
CHANGED_FILES: ${{ steps.checks.outputs.changedFiles }}
run: |
: Run clang-format 🐉
if (( ${+RUNNER_DEBUG} )) setopt XTRACE

local -a changes=($(git diff --name-only HEAD~1 HEAD))
case ${GITHUB_EVENT_NAME} {
pull_request) changes=($(git diff --name-only origin/${GITHUB_BASE_REF} HEAD)) ;;
push) if [[ ${GITHUB_EVENT_FORCED} != true ]] changes=($(git diff --name-only ${GITHUB_REF_BEFORE} HEAD)) ;;
*) ;;
}

if (( ${changes[(I)(*.c|*.h|*.cpp|*.hpp|*.m|*.mm)]} )) {
echo ::group::Install clang-format-17
brew install --quiet obsproject/tools/clang-format@17
echo ::endgroup::
print ::group::Install clang-format-19
brew install --quiet obsproject/tools/clang-format@19
print ::endgroup::

echo ::group::Run clang-format-17
./build-aux/run-clang-format --fail-${{ inputs.failCondition }} --check
echo ::endgroup::
}
print ::group::Run clang-format-19
local -a changes=(${(s:,:)CHANGED_FILES//[\[\]\'\"]/})
./build-aux/run-clang-format --fail-${{ inputs.failCondition }} --check ${changes}
print ::endgroup::
Loading