docs(python): make the display_mode default agree with code

Also adds the `environment` mode to the list of acceptable values.
This commit is contained in:
Michael Grubb 2024-09-10 09:40:55 -05:00 committed by Jan De Dobbeleer
parent bc483d677f
commit 80cf25d6a8

View file

@ -33,7 +33,7 @@ import Config from "@site/src/components/Config.js";
| `display_default` | `boolean` | `true` | show the name of the virtualenv when it's default (`system`, `base`) or not | | `display_default` | `boolean` | `true` | show the name of the virtualenv when it's default (`system`, `base`) or not |
| `fetch_version` | `boolean` | `true` | fetch the python version | | `fetch_version` | `boolean` | `true` | fetch the python version |
| `missing_command_text` | `string` | | text to display when the command is missing | | `missing_command_text` | `string` | | text to display when the command is missing |
| `display_mode` | `string` | `context` | <ul><li>`always`: the segment is always displayed</li><li>`files`: the segment is only displayed when file `extensions` listed are present</li><li>`context`: displays the segment when the environment or files is active</li></ul> | | `display_mode` | `string` | `environment` | <ul><li>`always`: the segment is always displayed</li><li>`files`: the segment is only displayed when file `extensions` listed are present</li><li>`environment`: the segment is only displayed when in a virtual environment</li><li>`context`: displays the segment when the environment or files is active</li></ul> |
| `version_url_template` | `string` | | a go [text/template][go-text-template] [template][templates] that creates the URL of the version info / release notes | | `version_url_template` | `string` | | a go [text/template][go-text-template] [template][templates] that creates the URL of the version info / release notes |
| `extensions` | `[]string` | `*.py, *.ipynb, pyproject.toml, venv.bak` | allows to override the default list of file extensions to validate | | `extensions` | `[]string` | `*.py, *.ipynb, pyproject.toml, venv.bak` | allows to override the default list of file extensions to validate |
| `folders` | `[]string` | | allows to override the list of folder names to validate | | `folders` | `[]string` | | allows to override the list of folder names to validate |