mirror of
https://github.com/starship/starship.git
synced 2026-06-22 02:02:12 +07:00
feat(python): Add scan_for_pyfiles option (#692)
Also adds two new entries to the list of hardcoded files to check: setup.py and __init__.py.
This commit is contained in:
@@ -1106,9 +1106,11 @@ The module will be shown if any of the following conditions are met:
|
||||
- The current directory contains a `.python-version` file
|
||||
- The current directory contains a `requirements.txt` file
|
||||
- The current directory contains a `pyproject.toml` file
|
||||
- The current directory contains a file with the `.py` extension
|
||||
- The current directory contains a file with the `.py` extension (and `scan_for_pyfiles` is true)
|
||||
- The current directory contains a `Pipfile` file
|
||||
- The current directory contains a `tox.ini` file
|
||||
- The current directory contains a `setup.py` file
|
||||
- The current directory contains a `__init__.py` file
|
||||
- A virtual environment is currently activated
|
||||
|
||||
### Options
|
||||
@@ -1118,6 +1120,7 @@ The module will be shown if any of the following conditions are met:
|
||||
| `symbol` | `"🐍 "` | The symbol used before displaying the version of Python. |
|
||||
| `pyenv_version_name` | `false` | Use pyenv to get Python version |
|
||||
| `pyenv_prefix` | `"pyenv "` | Prefix before pyenv version display (default display is `pyenv MY_VERSION`) |
|
||||
| `scan_for_pyfiles` | `true` | If false, Python files in the current directory will not show this module. |
|
||||
| `style` | `"bold yellow"` | The style for the module. |
|
||||
| `disabled` | `false` | Disables the `python` module. |
|
||||
|
||||
|
||||
Reference in New Issue
Block a user