Skip to content

Refactor: Implementation of PR #132 Architecture (Repository & Constants) - #174

Merged
snehmatic merged 7 commits into
mainfrom
refactor-core-architecture
Sep 21, 2026
Merged

snehmatic merged 7 commits into
mainfrom
refactor-core-architecture

Conversation

@snehmatic

Copy link
Copy Markdown
Owner

This PR cherry-picks and implements the core architectural improvements discussed in PR #132 without the merge conflicts. It includes:

  1. Extraction of inline errors to package-level variables across all 10 core modules.
  2. Replacing magic status strings with strongly-typed constants from models/constants.go.
  3. Refactoring UserConfig into a thread-safe singleton, significantly reducing file I/O operations and fixing pointer dereference bugs.
  4. Implementing the Repository Pattern across all 7 core data-managing modules (Task, Habit, Intent, Focus, Journal, Note, Quest), effectively untangling the core business logic from direct gorm.DB calls.

All tests are passing.
Please review.

@snehmatic
snehmatic merged commit afe3676 into main Sep 21, 2026
4 of 6 checks passed
@snehmatic
snehmatic deleted the refactor-core-architecture branch September 21, 2026 16:35
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.

1 participant