The script always exits 0. Output is empty (with a success message) when all strings are
used, or lists unused Strings.<name> references when unused keys are found.
Step 2 — Report findings
Present the results clearly to the user:
If exit code is 0: confirm all strings are in use, no action needed.
If exit code is 1: list the unused strings grouped by feature prefix (e.g. all practice*
together, all common* together) so the user can see the scope at a glance.
Do not remove anything yet. Wait for the user to decide.
Step 3 — Remove unused strings (only if asked)
If the user wants to remove unused strings:
For each unused key, remove its entry from the base Localizable.strings file (typically
en.lproj/Localizable.strings) using the Edit tool.
If the project has a buildStrings script in the project root, run it to regenerate
Strings.swift and any other derived string files:
./buildStrings
Verify by re-running the script to confirm no unused keys remain.
Note: Removing a string key deletes it from the source file permanently. Only do
this for keys you are certain are unused — check git history if in doubt.
1---2name: fgeistert-skills-check-unused-strings-ios3description: Check Unused Strings4---56# Check Unused Strings78Find localization keys in `Strings.swift` that are never referenced in Swift source files.910## Step 1 — Run the script1112```bash13python3 ~/.claude/skills/check-unused-strings-ios/scripts/checkUnusedStrings14```1516The script always exits 0. Output is empty (with a success message) when all strings are17used, or lists unused `Strings.<name>` references when unused keys are found.1819## Step 2 — Report findings2021Present the results clearly to the user:2223- If exit code is 0: confirm all strings are in use, no action needed.24- If exit code is 1: list the unused strings grouped by feature prefix (e.g. all `practice*`25 together, all `common*` together) so the user can see the scope at a glance.2627**Do not remove anything yet.** Wait for the user to decide.2829## Step 3 — Remove unused strings (only if asked)3031If the user wants to remove unused strings:32331. For each unused key, remove its entry from the base `Localizable.strings` file (typically34 `en.lproj/Localizable.strings`) using the Edit tool.35362. If the project has a `buildStrings` script in the project root, run it to regenerate37 `Strings.swift` and any other derived string files:3839 ```bash40 ./buildStrings41 ```42433. Verify by re-running the script to confirm no unused keys remain.4445> **Note:** Removing a string key deletes it from the source file permanently. Only do46> this for keys you are certain are unused — check git history if in doubt.4748---49> Source: [fgeistert/skills](https://github.com/fgeistert/skills) — distributed by [TomeVault](https://tomevault.io).50<!-- tomevault:4.0:skill_md:2026-06-16 -->
Run npx skillmds@latest add tomevault-io/fgeistert-skills-check-unused-strings-ios in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
Check Unused Strings It is listed under Coding & Dev Tools on SkillMD.
This skill has not completed SkillMD's automated safety review yet. Independent scanners report: SkillSpector: PASS, Skill Scanner: PASS. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
tomevault-io (@tomevault-io) published this skill. Their other Agent Skills are listed on their SkillMD profile.