Skip to content

Simplify command imports to help maintainability#320

Merged
pvdz merged 1 commit intomainfrom
simplify_imports
Feb 13, 2025
Merged

Simplify command imports to help maintainability#320
pvdz merged 1 commit intomainfrom
simplify_imports

Conversation

@pvdz
Copy link
Contributor

@pvdz pvdz commented Feb 13, 2025

Ok hear me out.

  • star exports are an anti-pattern because you don't really know what that file is exporting
  • it's easier to figure out which commands are exposed now because they are explicitly listed (at the cost of some verbosity)
  • the command objects are easier to grep for and easier to recognize (dependencies vs dependenciesCommand)
  • the pattern where the command run method was accessing its exported member to get the description feels a bit oof
  • 10 of the 121 "additions" are actually empty lines so the diff really only adds 111 lines vs 98 deleted and also it's just separating declarations and stuff for clarity and I'm planning to making all of that a bit more explicit and standard anyways and so ok who cares I guess.

This is the first step of many and I want to try and put them in separate commits for easy review and merging. Well. Merging will be my hell but ok.

@pvdz pvdz requested a review from jdalton February 13, 2025 12:08
@pvdz pvdz merged commit 02179ab into main Feb 13, 2025
15 checks passed
@pvdz pvdz deleted the simplify_imports branch February 13, 2025 12:33
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