Swiftui View Refactor
Dimillian/Skills
Refactor and review SwiftUI view files with strong defaults for small dedicated subviews, MV-over-MVVM data flow, stable view trees, explicit dependency injection, and correct Observation usage.
Code refactoring catalog. An agent skill from revfactory/harness-100.
$ npx skills add revfactory/harness-100 --skill refactoring-catalog -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install revfactory/harness-100 refactoring-catalog --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/revfactory/harness-100.git skills-src && mkdir -p .claude/skills && cp -r skills-src/en/21-code-reviewer/.claude/skills/refactoring-catalog .claude/skills/refactoring-catalog && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "refactoring-catalog" agent skill from https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalog into .claude/skills/refactoring-catalog/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-catalog", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalogType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add revfactory/harness-100 --skill refactoring-catalog -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install revfactory/harness-100 refactoring-catalog --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/revfactory/harness-100.git skills-src && mkdir -p .agents/skills && cp -r skills-src/en/21-code-reviewer/.claude/skills/refactoring-catalog .agents/skills/refactoring-catalog && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "refactoring-catalog" agent skill from https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalog into .agents/skills/refactoring-catalog/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-catalog", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add revfactory/harness-100 --skill refactoring-catalog -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install revfactory/harness-100 refactoring-catalog --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/revfactory/harness-100.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/en/21-code-reviewer/.claude/skills/refactoring-catalog .cursor/skills/refactoring-catalog && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "refactoring-catalog" agent skill from https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalog into .cursor/skills/refactoring-catalog/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-catalog", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/revfactory/harness-100.git --path en/21-code-reviewer/.claude/skills/refactoring-catalog--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add revfactory/harness-100 --skill refactoring-catalog -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install revfactory/harness-100 refactoring-catalog --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/revfactory/harness-100.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/en/21-code-reviewer/.claude/skills/refactoring-catalog .gemini/skills/refactoring-catalog && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "refactoring-catalog" agent skill from https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalog into .gemini/skills/refactoring-catalog/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-catalog", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install revfactory/harness-100 refactoring-catalogInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add revfactory/harness-100 --skill refactoring-catalog -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/revfactory/harness-100.git skills-src && mkdir -p .github/skills && cp -r skills-src/en/21-code-reviewer/.claude/skills/refactoring-catalog .github/skills/refactoring-catalog && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "refactoring-catalog" agent skill from https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalog into .github/skills/refactoring-catalog/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-catalog", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add revfactory/harness-100 --skill refactoring-catalog -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install revfactory/harness-100 refactoring-catalog --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/revfactory/harness-100.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/en/21-code-reviewer/.claude/skills/refactoring-catalog .opencode/skills/refactoring-catalog && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "refactoring-catalog" agent skill from https://github.com/revfactory/harness-100/tree/main/en/21-code-reviewer/.claude/skills/refactoring-catalog into .opencode/skills/refactoring-catalog/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "refactoring-catalog", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
refactoring-catalogCode refactoring catalog. An agent skill from revfactory/harness-100.
Refactoring Catalog is an agent skill from revfactory/harness-100. Code refactoring catalog. An extension skill for architecture-reviewer/performance-analyst that provides Martin Fowler-based refactoring patterns, code smell detection-to-refactoring mapping, SOLID principle violation identification, and complexity measurement criteria. Use when reviewing code structure improvement involving 'refactoring', 'code smells', 'SOLID violations', 'complexity', 'design patterns', 'code quality', etc. Note: direct code modification and security analysis are outside the scope of this skill.
Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Development, covering Refactoring and Design patterns. The licence is Apache-2.0.
Read from SKILL.md and the folder at commit 8e8d35c. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Refactoring Catalog loads about 1.8k tokens when it runs. Until then it costs about 135 tokens; SKILL.md has 621 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from revfactory/harness-100 at commit 8e8d35c, republished under its Apache-2.0 licence (© revfactory). 621 words, ~1,786 tokens.
.claude/skills/refactoring-catalog/SKILL.md (or your agent's skills folder).A reference of code smell-to-refactoring mappings, SOLID violation identification, and complexity metrics used by the architecture-reviewer and performance-analyst agents during code structure analysis.
architecture-reviewer — Applied when suggesting refactoring based on design patterns and SOLID principlesperformance-analyst — Applied when suggesting refactoring related to complexity analysis and performance| Code Smell | Symptoms | Refactoring Technique |
|---|---|---|
| Long Method | 20+ lines | Extract Method, Replace Temp with Query |
| Large Class | 300+ lines or 10+ fields | Extract Class, Extract Subclass |
| Long Parameter List | 4+ parameters | Introduce Parameter Object, Builder Pattern |
| Data Clumps | Same field groups repeated | Extract Class |
| Primitive Obsession | Domain concepts as primitives | Value Object, Enum |
| Code Smell | Symptoms | Refactoring Technique |
|---|---|---|
| Feature Envy | Excessive use of another class's data | Move Method |
| Data Class | Class with only getters/setters | Move behavior into class |
| Shotgun Surgery | One change affects multiple classes | Move Method/Field, Inline Class |
| Divergent Change | One class changes for multiple reasons | Extract Class (SRP) |
| Duplicated Code | Identical/similar code repeated | Extract Method, Template Method |
| Middle Man | Class that only delegates | Remove Middle Man, Inline Class |
| Inappropriate Intimacy | Excessive coupling between classes | Move Method/Field, Extract Class |
| Switch/If Chain | Long conditional branching | Replace Conditional with Polymorphism, Strategy |
| Refused Bequest | Inherited but unused methods | Replace Inheritance with Delegation |
| Comments | Complex logic explained by comments | Extract Method (self-documenting code) |
| Violation Signal | Identification Criteria | Refactoring |
|---|---|---|
| Class name contains "And", "Manager" | Implies multiple responsibilities | Extract Class |
| 2+ reasons to change | "If X changes this class changes, and if Y changes this class also changes" | Separate classes by responsibility |
| Highly diverse imports | Imports DB, HTTP, UI, logging all together | Layer separation |
| Violation Signal | Identification Criteria | Refactoring |
|---|---|---|
| Switch/if modified when adding new types | Existing code modification required | Strategy Pattern, Polymorphism |
| Hardcoded branching | Code added for each new condition | Plugin/Registry pattern |
| Violation Signal | Identification Criteria | Refactoring |
|---|---|---|
| Override throws exception in child class | NotImplementedError, UnsupportedOperationException | Interface segregation, Inheritance to Composition |
| Type checking then casting | instanceof / typeof branching | Redesign with polymorphism |
| Violation Signal | Identification Criteria | Refactoring |
|---|---|---|
| Empty interface implementations | pass, {}, noop | Interface segregation |
| "Fat" interface | 10+ methods | Split into Role Interfaces |
| Violation Signal | Identification Criteria | Refactoring |
|---|---|---|
| Direct concrete class instantiation | Hardcoded new ConcreteService() | Dependency Injection |
| Upper module imports lower module | Business logic directly uses DB library | Interface/Port abstraction |
Branch points (if/else/switch/for/while/catch) + 1
| Score | Complexity | Action |
|---|---|---|
| 1-5 | Low | Appropriate |
| 6-10 | Medium | Review with care |
| 11-20 | High | Refactoring recommended |
| 21+ | Very high | Refactoring required |
Difficulty of human code comprehension. Weight increases with deeper nesting.
| Element | Base Increment | Nesting Bonus |
|---|---|---|
| if/else/switch | +1 | +nesting level |
| for/while/do | +1 | +nesting level |
| catch | +1 | +nesting level |
| break/continue to label | +1 | - |
| Logical operator chain (&&, | ) | |
| Recursive call | +1 | - |
| Metric | Method/Function | Class/File |
|---|---|---|
| Lines of code | Under 20 | Under 300 |
| Cyclomatic complexity | 10 or less | - |
| Cognitive complexity | 15 or less | - |
| Parameter count | 4 or less | - |
| Nesting depth | 3 levels or less | - |
| Dependency count | - | 10 or less |
| Problem Situation | Applicable Pattern | Effect |
|---|---|---|
| Behavioral branching via conditionals | Strategy | OCP compliance, easy to add new behaviors |
| Complex object creation logic | Factory Method/Builder | Encapsulate creation logic |
| Same algorithm skeleton, different details | Template Method | Remove duplication, isolate change points |
| Behavior changes based on state | State | Remove conditionals, clarify state transitions |
| Event propagation to multiple objects | Observer | Loose coupling |
| Integrating incompatible interfaces | Adapter | Integration without modifying existing code |
| Simplifying complex subsystems | Facade | Interface simplification |
| Dynamically adding features to objects | Decorator | Feature extension without inheritance |
| Low Difficulty | High Difficulty | |
|---|---|---|
| High Impact | Do immediately | Plan then execute |
| Low Impact | When time allows | Defer (low cost-benefit) |
[Severity] Code Smell: [Smell Name]
Location: [File:Line]
Current State: [Problem description]
Refactoring: [Technique name]
Expected Effect: [How it improves]
Estimated Difficulty: [Low/Medium/High]© revfactory, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in en/21-code-reviewer/.claude/skills/refactoring-catalog of revfactory/harness-100.
Open the folder on GitHubat commit 8e8d35c
Refactoring Catalog next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Refactoring Catalog this skillrevfactory/harness-100 | 1.3k | — | ~1.8k | Automated safety check: Pass | Apache-2.0 | |
| Swiftui View RefactorDimillian/Skills | 4k | 5 repos | ~2k | Automated safety check: Pass | MIT | |
| RTK Rust Design Patternsrtk-ai/rtk | 83k | — | ~1.9k | Automated safety check: Pass | Apache-2.0 | |
| Architecture PatternsKartikLabhshetwar/better-shot | 2.4k | 2 repos | ~1.4k | Automated safety check: Pass | Custom licence | |
| AST Visitor Pattern for Unionsprisma/orm | 48k | — | ~830 | Automated safety check: Pass | Apache-2.0 | |
| Solidramziddin/solid-skills | 606 | — | ~2.7k | Automated safety check: Pass | None |
Dimillian/Skills
Refactor and review SwiftUI view files with strong defaults for small dedicated subviews, MV-over-MVVM data flow, stable view trees, explicit dependency injection, and correct Observation usage.
rtk-ai/rtk
Describes seven Rust design patterns for the RTK CLI filter modules, with when to use each, RTK examples, and notes on when a pattern is overkill.
KartikLabhshetwar/better-shot
Deep dive into software architecture for macOS. An agent skill from KartikLabhshetwar/better-shot.
prisma/orm
Replaces a plain TypeScript union plus switch statements with frozen subclasses and a visitor interface when several places dispatch on the same variants.
ramziddin/solid-skills
A skill your agent uses when writing code, implementing features, refactoring, planning architecture, designing systems, reviewing code, or debugging.
harperreed/dotfiles
Refactor and review SwiftUI view files for consistent structure, dependency injection, and Observation usage.
revfactory/harness-100
A skill for analyzing website anti-bot defense mechanisms and developing legitimate evasion strategies.
revfactory/harness-100
Reference for designing how an API reports failures: structured error codes, response shapes, client-friendly messages, an error catalog and retry or fallback advice.
revfactory/harness-100
Walks a backend-dev agent through OWASP API Top 10 checks, authentication and authorization patterns, and defense code during API design.
revfactory/harness-100
Methodology for systematically designing and generating CLI tool argument parser structures.
revfactory/harness-100
Audience segmentation skill used by the analyst and curator agents.
revfactory/harness-100
Audio storytelling skill used by the podcast scriptwriter and show note editor.
Categories
Code refactoring catalog. An agent skill from revfactory/harness-100. Refactoring Catalog is an agent skill from revfactory/harness-100. Code refactoring catalog.
Refactoring Catalog fits situations like: reviewing code structure improvement involving refactoring; SOLID violations; design patterns.
Run `npx skills add revfactory/harness-100 --skill refactoring-catalog -a claude-code`. Or copy the skill folder (en/21-code-reviewer/.claude/skills/refactoring-catalog in revfactory/harness-100) into .claude/skills/refactoring-catalog in your project. Claude Code loads it when a task matches its description.
Run `npx skills add revfactory/harness-100 --skill refactoring-catalog -a codex`. Or copy the skill folder (en/21-code-reviewer/.claude/skills/refactoring-catalog in revfactory/harness-100) into .agents/skills/refactoring-catalog in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add revfactory/harness-100 --skill refactoring-catalog -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/refactoring-catalog, .gemini/skills/refactoring-catalog, .github/skills/refactoring-catalog and .opencode/skills/refactoring-catalog in your project.
SKILL.md names no scripts, command-line tools or credentials: Refactoring Catalog is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Refactoring Catalog is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.8k tokens (SKILL.md is roughly 7.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Refactoring Catalog: Swiftui View Refactor (Dimillian/Skills, 4k stars), RTK Rust Design Patterns (rtk-ai/rtk, 83k stars), Architecture Patterns (KartikLabhshetwar/better-shot, 2.4k stars) and AST Visitor Pattern for Unions (prisma/orm, 48k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
revfactory (a GitHub user) maintains it in revfactory/harness-100, which has 1,290 GitHub stars. The repository holds 464 skills in this directory. The repository was last updated on March 22, 2026.
Source: revfactory/harness-100 on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.