Add installer build tooling, CI workflow, and cross-platform Lua runtime support - #3
Add installer build tooling, CI workflow, and cross-platform Lua runtime support#3eimexdev wants to merge 2 commits into
Conversation
ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Free Run ID: 📒 Files selected for processing (3)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughAdds platform-specific installer build support: a GitHub Actions workflow to build macOS and Windows installers, a local Python build script using PyInstaller to produce packaged installers and payloads, cross-platform path/env handling in OpenBeat Lua code, and README updates documenting installer usage and local builds. Changes
sequenceDiagram
autonumber
participant GH as "GitHub Actions"
participant Repo as "Repository"
participant Builder as "scripts/build_installers.py"
participant PyInstaller as "PyInstaller"
participant PKG as "pkgbuild (macOS)"
participant Uploader as "actions/upload-artifact"
GH->>Repo: checkout code
GH->>Repo: setup Python 3.11, pip, install deps
GH->>Builder: run python scripts/build_installers.py --platform (macos|windows)
Builder->>PyInstaller: build one-file CLI (per-platform)
Builder->>Repo: stage Fusion payload (resolve/Fusion/...)
alt macOS
Builder->>PKG: create pkg with staged payload and postinstall
PKG-->>Builder: produced OpenBeat-macos-<ver>.pkg
else Windows
Builder->>PyInstaller: build installer exe bundling payload
PyInstaller-->>Builder: produced OpenBeat-windows-<ver>-installer.exe
end
Builder->>Uploader: upload produced installer artifact(s)
Uploader-->>GH: artifact available
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Poem
Note 🎁 Summarized by CodeRabbit FreeYour organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login. Comment |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 3179561f26
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if lowered:match("python%.exe$") or lowered:match("python$") then | ||
| return shell_quote(bin) .. " -m openbeat.cli" |
There was a problem hiding this comment.
Preserve module invocation for python3 fallback
When no OpenBeatConfig.local.lua is present and no project virtualenv is found, python_bin() falls back to python3, but command_prefix() only appends -m openbeat.cli for executables ending in python or python.exe. In that common fallback path the command becomes python3 analyze ... / python3 click-track ..., which fails because Python treats analyze as a script name instead of a module subcommand; this is a regression from the previous behavior that always used -m openbeat.cli.
Useful? React with 👍 / 👎.
| if args.platform in ("macos", "all"): | ||
| outputs.append(create_macos_dmg(cli_binary=cli_binary, version=version)) | ||
|
|
||
| if args.platform in ("windows", "all"): | ||
| outputs.append(create_windows_exe(cli_binary=cli_binary, version=version, python_bin=args.python)) |
There was a problem hiding this comment.
Avoid defaulting installer builds to unsupported cross-OS mode
The default --platform value is all, and the main flow executes both macOS and Windows packaging branches for that mode; this makes the default command fail on a normal single-OS machine because each branch depends on OS-specific tooling/artifacts (e.g., hdiutil for macOS and .exe output assumptions for the Windows branch). As written, the documented local command path using defaults is not runnable unless callers always remember to override --platform.
Useful? React with 👍 / 👎.
Motivation
Description
/.github/workflows/build-installers.ymlto build installers formacosandwindowsand upload artifacts namedopenbeat-<platform>-installer.scripts/build_installers.pywhich invokesPyInstallerto produce a single-file CLI binary and then packages a macOS.dmg(install.command) and a Windows installer.exe(single-file PyInstaller wrapper that installs files into the Resolve Fusion folders).resolve/Fusion/Modules/OpenBeat/OpenBeatCommon.luato be cross-platform by normalizing path separators, addingis_windows,path_sep, Windows-safeshell_quote,command_prefix, improvedpython_bindetection (including.venv/Scripts/python.exe), portabletemp_path, and Windows-aware logging paths; switch calls likeanalyze_sourceandrender_click_trackto use the new command prefix.README.mdto document the new installer options and local build steps, and addbuild/anddist/to.gitignoreto avoid committing build artifacts.Testing
Build Installers) which will run onpush,pull_request, andworkflow_dispatchand will perform the automated build steps when triggered.Codex Task
Summary by CodeRabbit
New Features
Documentation
Quality of Life