Agent Skills
› robinebers/openusage
› build-and-run-macos-app
build-and-run-macos-app
GitHub为 macOS 项目创建或更新本地构建运行脚本,自动检测 Xcode 或 SwiftPM 工程结构,统一封装停止、构建和启动流程,支持多种调试与验证模式。
Trigger Scenarios
用户需要标准化 macOS 应用的构建和启动流程
项目缺乏统一的 build_and_run.sh 入口脚本
Install
npx skills add robinebers/openusage --skill build-and-run-macos-app -g -y
SKILL.md
Frontmatter
{
"name": "build-and-run-macos-app",
"description": "Slash command that creates or updates the project-local macOS `script\/build_and_run.sh` and uses it as the default build\/run entrypoint. Invoke explicitly with \/build-and-run-macos-app — this skill never self-triggers.",
"disable-model-invocation": true
}
Build And Run macOS App
Create or update the project-local macOS build_and_run.sh script, then use
that script as the default build/run entrypoint.
Arguments
scheme: Xcode scheme name (optional)workspace: path to.xcworkspace(optional)project: path to.xcodeproj(optional)product: SwiftPM executable product name (optional)mode:run,debug,logs,telemetry, orverify(optional, default:run)app_name: process/app name to stop before relaunching (optional)
Workflow
- Detect whether the repo uses an Xcode workspace, Xcode project, or SwiftPM package.
- If the workspace is not inside git yet, run
git initat the project root so git-backed editor features unlock. - Create or update
script/build_and_run.shso it always stops the current app, builds the macOS target, and launches the fresh result. - For SwiftPM, keep raw executable launch only for true CLI tools; for AppKit/SwiftUI GUI apps, create a project-local
.appbundle and launch it with/usr/bin/open -n. - Support optional script flags for
--debug,--logs,--telemetry, and--verify. - Follow the canonical bootstrap contract in
../build-run-debug/references/build-script.mdfor the exact script shape. - Run the script in the requested mode and summarize any build, script, or launch failure.
Guardrails
- Do not initialize a nested git repo inside an existing parent checkout.
- Keep the no-flag script path simple: kill, build, run.
- Use
--debug,--logs,--telemetry, or--verifyonly when the user asks for those modes.
Version History
- 70acd4f Current 2026-08-20 09:01


