-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conquer the land of clicketing snakes #13
Conversation
Just had to change a bit the imports in EDIT: hmm the arguments are not passed correctly, back to draft. |
Any examples of projects using Click so I can test it on them? HTTPX seems to use its own formatted help (same output with and without rich-click). |
Brilliant stuff! 👏🏻 I'm on holiday this week so won't get a chance to properly review + merge until after that, but love the idea / look of it.. Phil |
No problem, enjoy your holidays! |
So there's just one more thing to decide on: whether to implement rich-click's own CLI with click or not. |
Yeah I did wonder about commenting about that! Seems a bit hypocritical not to somehow 😅 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I had a stab at running locally but ran into some issues..
Note to self: need to add the new entry points into the conda-forge Example here, so something like this I guess: build:
entry_points:
- rich-click=rich_click.cli:main |
That fixed it! 🎉 |
ok, so using click to handle the CLI was difficult because of the weird argument handling (we don't want click to interpret any option flags). Instead, I tried to fake it - using as many of the rich-click functions and variables as possible so that the help text tracks with updates to the package. This is what I now get: I'll push this directly to your PR if that's ok @pawamoy - I should PR to your feature branch really, but it's late.. 😁 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love it, working a treat in my hands now - thanks for this!
I don't think I'd have ever believed that this would work had you not put in this PR 😅
Totally fine! And great work! I feared indeed that rewriting the CLI using click would be tricky, but you managed to do it well 😄 |
Twin sister of chriskiehl/Gooey#788 :D
Original PR title: Allow to run any Click program from the CLI :p