tidying

Apply small, safe structural tidying to messy code without altering behavior.

6|Updated Dec 28, 2023
One-click install
npx skills add https://github.com/staticWagomU/dotfiles --skill tidying-staticwagomu
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tidying
Source: https://github.com/staticWagomU/dotfiles/tree/main/config/claude/skills/tidying
Command: npx skills add https://github.com/staticWagomU/dotfiles --skill tidying-staticwagomu

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Guide structural code improvements using Kent Beck's Tidy First methodology. Use when seeing messy code, before making behavioral changes, after completing features, or discussing when to clean up code.

Core Features & Use Cases

  • Apply Kent Beck's "Tidy First?" philosophy: small, safe structural changes that improve code without changing behavior. Tidying is separate from feature work and gets its own commits.
  • Tidying Catalog:
  • Guard Clauses
  • Dead Code
  • Normalize Symmetries
  • Extract Helper
  • Inline
  • Rename
  • Reorder
  • Chunk Statements
  • Explaining Variable
  • Explaining Constant
  • Decision Framework
  • Integration with TDD
  • Commit Discipline
  • Anti-Patterns
  • Reference

Quick Start

Identify messy code areas and apply small, safe structural tidying before introducing behavioral changes.

Frequently Asked Questions about tidying

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I refactor messy code without changing its behavior?

Refactor messy code safely by applying small, targeted structural tidying steps like guard clauses or renaming, keeping these changes isolated in separate commits before any behavioral changes.

What is the Tidy First methodology for software engineering?

Tidy First is a methodology for structural code improvements where developers apply small, safe changes to improve readability and maintainability, keeping tidying entirely separate from feature work.

When should I apply code tidying during development?

Apply code tidying when you see messy code, before making behavioral changes, after completing features, or during code reviews to improve maintainability and readability.

What small refactoring steps can I use to improve code maintainability?

Improve code maintainability using specific tidying steps like extracting helpers, inlining code, normalizing symmetries, chunking statements, and introducing explaining variables or constants.

How does structural tidying integrate with TDD?

Structural tidying integrates with TDD by ensuring safe, incremental code improvements are made in isolated steps with separate commits, maintaining test integrity during refactoring.

What are the anti-patterns to avoid when tidying code?

Avoid anti-patterns in code tidying by following a defined workflow with incremental, isolated steps and strict commit discipline, preventing structural changes from mixing with behavioral modifications.