Conversation
…ser. This simplifies the process for overriding cmd2's default parser class.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1458 +/- ##
==========================================
- Coverage 98.50% 98.50% -0.01%
==========================================
Files 20 20
Lines 5566 5605 +39
==========================================
+ Hits 5483 5521 +38
- Misses 83 84 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
…parser.py Also: - Delete unused chunk from plugin pyproject.toml - Upgrade version of ruff used by pre-commit
tleonhardt
left a comment
There was a problem hiding this comment.
Everything here looks good to me.
Would it be feasible to move most of the parser building logic to a separate file? If so would it be desirable?
My thought is that cmd2.py is a pretty large file. If it is possible to move a good chunk of related logic to a separate file, that might be a good thing. Given that many if not most of the parser builder functions are class methods, I suspect this might be impossible or painful. But it's worth a thought.
All built-in commands now use a function to create their argument parser.
This simplifies the process for overriding cmd2's default parser class.