Poetry plugin
March 11, 2025 ยท View on GitHub
This is my personal opinionated plugin for Oh My ZSH! that adds aliases for my most freqently used poetry commands.
Installation
- copy the
poetry.plugin.zshfile to your$ZSH_CUSTOM/plugins/poetryfolder
mkdir $ZSH_CUSTOM/plugins/poetry
cp poetry.plugin.zsh $ZSH_CUSTOM/plugins/poetry
- add
poetryto the plugins array in your zshrc file:
plugins=(... poetry)
- Reload with
omz reload - (Optional) Enable tab completion for poetry (read poetry doc)
Aliases
| Alias | Command | Description |
|---|---|---|
poe | poetry | Poetry command |
poi | poetry install | Install dependencies |
por | poetry run | Run command in Poetry environment: por <command> |
pot | poetry run pytest -s | Run pytest with output capturing disabled |
poad | poetry add | Add a dependency: poad <package> |
poadd | poetry add --dev | Add a dev dependency: poadd <package> |
porm | poetry remove | Remove a dependency: porm <package> |
mkserve | poetry run mkdocs serve | Run MkDocs development server |