Textualize / rich-cli

Rich-cli is a command line toolbox for fancy output in the terminal
https://www.textualize.io
MIT License
3.04k stars 75 forks source link

feat: support pipx run #6

Closed henryiii closed 2 years ago

henryiii commented 2 years ago

Pipx (https://github.com/pypa/pipx) expects a package to have a console entry point matching the name of the package. If this is not the case (rich-cli package with rich after installing), then you can tell pipx this is the case by adding a pipx entry-point[^1].

# before
pipx run --spec rich-cli rich <args>
# after
pipx run rich-cli <args>

[^1]: Entry-points are called plugin in Poetry, not to be confused with a poetry plugin, which will look like [tool.poetry.plugins."poetry.plugin"] :facepalm:

henryiii commented 2 years ago

Modern versions of pipx guess that a single CLI entry point is supposed to be called; this silences that warning.

pipx run rich-cli --help
NOTE: running app 'rich' from 'rich-cli'
willmcgugan commented 2 years ago

Thanks