Split the app into subapps, adding categories to it - #14
Merged
fillipe-gsm merged 15 commits intoDec 9, 2025
Conversation
Now, instead of `kanban-cli view-all` we should run `kanban-cli tasks view-all`, for instance. This should make this more organized and make more sense when adding `categories` as a new app
This required a bunch of moving around and changes in a bunch of files
A category with linked tasks cannot be deleted to prevent issues with data integrity.
It should now be possible to add, view, edit and delete categories from the cli via the `categories` subapp.
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR restructures the application by splitting functionality into separate sub-apps for tasks and categories, introducing a breaking CLI change where commands now require a subcommand prefix (e.g., kanban-cli tasks add instead of kanban-cli add).
Key Changes:
- Moved the
Categorymodel fromsrc/tasks/models/to a newsrc/categories/models/module - Created a new
categoriessub-app with CRUD operations for category management - Refactored the main app to register both
tasksandcategoriesas separate Typer sub-applications
Reviewed Changes
Copilot reviewed 34 out of 42 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
src/app/app.py |
Refactored to register tasks and categories as sub-apps instead of direct commands |
src/tasks/tasks_app.py |
New file extracting task-related commands into a separate Typer app |
src/categories/categories_app.py |
New file implementing category management commands |
src/categories/models/category.py |
Moved from tasks module and added new methods for listing and editing |
src/categories/controllers/*.py |
New controllers for category CRUD operations |
src/categories/presenters/*.py |
New presenters for category-related UI output |
src/tasks/models/task.py |
Updated import path for Category model |
tests/**/*.py |
Updated import paths and test invocations to match new app structure |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Handles #10
This pull request does two things:
categoriessub-app to the main app;tasksas well.This adds a breaking change to everything, so now the previous
kanban-cli addshould becomekanban-cli tasks addand so on.