fix-codesign-error — Claude command: debug macOS signing failures
Inspects a macOS signing or entitlement failure and lays out the shortest fix path. Useful when a build refuses to launch or fails validation.
~/.codex/prompts/fix-codesign-error.mdWhat fix-codesign-error does
The command reads the .app bundle, the executable, signing info and entitlements. Then it names the failure class: identity, provisioning, hardened runtime, sandboxing or trust policy. You get a plain-language summary plus the minimal repair sequence or a validation command.
Arguments are optional. app takes a path to a bundle or binary, identity is a signing identity hint, mode is either inspect or repair-plan. The default is inspect, so the first pass is diagnosis only.
The guardrails matter here. Entitlements are read from the binary or source files, never invented. Local development signing problems stay separate from distribution or notarization failures. Verification leans on codesign -d, spctl and plutil rather than guesswork. If your local run is broken and the release build is fine, that is a reason to pass mode as repair-plan straight away.
What it helps with
- find out why a freshly built
.appwill not launch - tell a signing problem apart from a notarization failure
- read entitlements from the binary instead of guessing
- get the minimal command sequence to repair a signature
- validate a signature with
codesign -dandspctl
Example prompts for the agent
- /fix-codesign-error app=build/MyApp.app
- /fix-codesign-error app=build/MyApp.app mode=repair-plan
- /fix-codesign-error app=build/MyApp.app identity="Developer ID Application"
How to install fix-codesign-error
Manually: put the files in place
~/.codex/prompts/fix-codesign-error.mdCall it with /prompts:fix-codesign-error. Codex marks this format deprecated in favour of skills
Manually: put the files in place
.claude/commands/fix-codesign-error.mdCall it with /fix-codesign-error. For all projects use ~/.claude/commands/
Manually: put the files in place
.github/prompts/fix-codesign-error.prompt.mdManually: put the files in place
.gemini/commands/fix-codesign-error.tomlGemini stores commands as TOML: the prompt text goes into the prompt field
Questions about fix-codesign-error
How do I install fix-codesign-error in Claude?
Place the prompt file at ~/.codex/prompts/fix-codesign-error.md.
What does fix-codesign-error do?
It inspects the bundle, binary, signing info and entitlements, states the failure class, and returns the minimal repair sequence or validation command.
What arguments does the command take?
app for the bundle or binary path, identity as a signing hint, and mode set to inspect or repair-plan. With no arguments it runs in inspect mode.
Source text
fix-codesign-error.md · MIT
# /fix-codesign-error Inspect a macOS signing or entitlement failure and explain the minimum fix path. ## Arguments - `app`: path to `.app` bundle or binary (optional) - `identity`: signing identity hint (optional) - `mode`: `inspect` or `repair-plan` (optional, default: `inspect`) ## Workflow 1. Inspect the app bundle, executable, signing info, and entitlements. 2. Determine whether the problem is identity, provisioning, hardened runtime, sandboxing, or trust policy. 3. Summarize the exact failure class in plain language. 4. Provide the minimal repair sequence or validation command. ## Guardrails - Never invent entitlements; read them from the binary or source files. - Distinguish local development signing problems from distribution or notarization failures. - Prefer verifiable commands like `codesign -d`, `spctl`, and `plutil` over guesswork.
© OpenAI · MIT · openai/plugins