I really like having global cli command installed with pipx. Since textual
0.2.x (the css release) is out I want to be able to pop into textual devtools
easily from anywhere.
You can pipx install textual.
pipx install textual
But if you try to run any textual cli commands you will run into a
ModuleNotFoundError, because you need to install the optional
Traceback (most recent call last): File "/home/u_walkews/.local/bin/textual", line 5, in <module> from textual.cli.cli import run File "/home/u_walkews/.local/pipx/venvs/textual/lib/python3.10/site-packages/textual/cli/cli.py", line 4, in <module> import click ModuleNotFoundError: No module named 'click'
In order to install optional dependencies with
pipx you need to first install
the library, then inject in the optional dependencies using the square bracket
pipx install textual pipx inject textual 'textual[dev]'