Skip to content

Refactor CLI into modular command files - #35

Merged
TheBoatyMcBoatFace merged 2 commits into
mainfrom
click-commands
Mar 2, 2026
Merged

Refactor CLI into modular command files#35
TheBoatyMcBoatFace merged 2 commits into
mainfrom
click-commands

Conversation

@Tom-Camp

@Tom-Camp Tom-Camp commented Feb 13, 2026

Copy link
Copy Markdown
Member

📝 One-line Summary

Moves the Click commands from cli to /commands and the function from allusgov.py to the individual command files.

Issue: #1234 (if applicable)


📖 Description

  • Extracted all Click commands from cli.py into dedicated modules under commands/.
  • Kept the public CLI surface unchanged; command names, options, and behavior remain the same.
  • cli.py now only defines the root Click group and registers commands from commands/.
  • This makes it easier to:
    • Add new commands without touching a large cli.py or allusgov.py.
    • Maintain and test each command in isolation.
    • Share business logic between commands via regular Python modules instead of one large file.

🔧 Type of Change

Indicate all that apply:

  • 🆕 New feature (adds new functionality)
  • 🐛 Bug fix (non-breaking fix for a known issue)
  • 🔧 Configuration change
  • ♻️ Code refactor / performance improvement
  • 📝 Documentation or non-code contribution

✅ Tasks to Complete

Checklist of work being delivered in this PR:

  • Add/modify feature logic
  • Write or update documentation
  • Add or update tests
  • Accessibility review
  • Internal stakeholder check-in

👀 Review Checklist

For reviewers to verify before approving:

  • Code follows project conventions
  • Documentation is clear and complete
  • Tests added or updated
  • CHANGELOG updated (if applicable)
  • No major accessibility regressions

🚀 Deployment Notes

Are there migrations, feature flags, config updates, or coordination steps required?

@TheBoatyMcBoatFace
TheBoatyMcBoatFace merged commit 95826cb into main Mar 2, 2026
8 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants