mirror of
https://github.com/dcarrillo/prezto.git
synced 2025-07-02 01:39:25 +00:00
general: Update documentation better qualifying runcom paths
Zsh and Prezto files don't always reside in `~/`. Instead, they have a more spec compliant location (`${ZDOTDIR:-$HOME}/`). Make them unambiguous in the documentation. Likewise, for `$GNUPGHOME`. Further, add instruction for optionally setting up Prezto in `$XDG_CONFIG_HOME`. While at this, also add clarification on relative ordering of some of the modules, apply more formatting tweaks and doc improvements.
This commit is contained in:
committed by
Indrajit Raychaudhuri
parent
424d4cb779
commit
1ff9421f7b
@ -6,19 +6,19 @@ Loads prompt [themes][1].
|
||||
|
||||
### Prompt Theme
|
||||
|
||||
To select a prompt theme, add the following to *~/.zpreztorc*, and replace
|
||||
**name** with the name of the theme you wish to load. Setting it to **random**
|
||||
will load a random theme.
|
||||
To select a prompt theme, add the following to _`${ZDOTDIR:-$HOME}/.zpreztorc`_,
|
||||
and replace `'<name>'` with the name of the theme you wish to load. Setting it
|
||||
to `'random'` will load a random theme every time.
|
||||
|
||||
```sh
|
||||
zstyle ':prezto:module:prompt' theme 'name'
|
||||
zstyle ':prezto:module:prompt' theme '<name>'
|
||||
```
|
||||
|
||||
### Prompt Display Length
|
||||
|
||||
To change working directory prompt display length from 'short', set the
|
||||
following to 'long' (without `~` expansion) or 'full' (with `~` expansion) in
|
||||
*~/.zpreztorc*.
|
||||
_`${ZDOTDIR:-$HOME}/.zpreztorc`_.
|
||||
|
||||
```sh
|
||||
zstyle ':prezto:module:prompt' pwd-length 'short'
|
||||
@ -37,13 +37,13 @@ zstyle ':prezto:module:prompt' show-return-val 'no'
|
||||
|
||||
A prompt theme is an autoloadable function file with a special name,
|
||||
`prompt_name_setup`, placed anywhere in `$fpath`, but for the purpose of this
|
||||
project, themes **should** be placed in the *modules/prompt/functions*
|
||||
project, themes **should** be placed in the _modules/prompt/functions_
|
||||
directory.
|
||||
|
||||
### Required Variables
|
||||
|
||||
To ensure that your function works with the editor-info module you'll need to
|
||||
set the following variable in *~/.zpreztorc*:
|
||||
set the following variable in _`${ZDOTDIR:-$HOME}/.zpreztorc`_:
|
||||
|
||||
```sh
|
||||
# Tell prezto we can manage this prompt
|
||||
@ -119,7 +119,7 @@ function prompt_name_preview {
|
||||
|
||||
### Hook Functions
|
||||
|
||||
There are many Zsh [hook][2] functions, but mostly the *precmd* hook will be
|
||||
There are many Zsh [hook][2] functions, but mostly the _precmd_ hook will be
|
||||
used.
|
||||
|
||||
#### `prompt_name_precmd`
|
||||
@ -156,7 +156,7 @@ patched fonts][5] which should fix most font issues.
|
||||
|
||||
## Authors
|
||||
|
||||
*The authors of this module should be contacted via the [issue tracker][3].*
|
||||
_The authors of this module should be contacted via the [issue tracker][3]._
|
||||
|
||||
- [Sorin Ionescu](https://github.com/sorin-ionescu)
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
# - The prompt is prefixed by a character sequence of your choice.
|
||||
# - Only displays the current directory instead of the full path.
|
||||
# - Displays the current branch when in a git project (this requires loading
|
||||
# the git module before prompt in ~/.zpreztorc).
|
||||
# the git module before prompt in ${ZDOTDIR:-$HOME}/.zpreztorc).
|
||||
# - Displays a character at the end of the prompt when in a git project with
|
||||
# "dirty" files.
|
||||
#
|
||||
@ -17,7 +17,7 @@
|
||||
# This prompt's prefix symbol and colors are customizable:
|
||||
# prompt cloud [<symbol>] [<color1>] [<color2>]
|
||||
#
|
||||
# In ~/.zpreztorc:
|
||||
# In ${ZDOTDIR:-$HOME}/.zpreztorc:
|
||||
# zstyle ':prezto:module:prompt' theme 'cloud' \
|
||||
# ['<symbol>'] \
|
||||
# ['<color1>'] \
|
||||
@ -53,7 +53,7 @@ This prompt's prefix symbol and colors are customizable:
|
||||
|
||||
prompt cloud [<symbol>] [<color1>] [<color2>]
|
||||
|
||||
In ~/.zpreztorc:
|
||||
In ${ZDOTDIR:-$HOME}/.zpreztorc:
|
||||
zstyle ':prezto:module:prompt' theme 'cloud' ['<symbol>'] ['<color1>'] ['<color2>']
|
||||
|
||||
If these options are not provided, the symbol defaults to ☁ with colors cyan
|
||||
|
@ -18,7 +18,7 @@ WARNING: Prezto does not support 'powerlevel9k' anymore as it has
|
||||
been deprecated and is not supported by its author.
|
||||
Consider migrating to 'powerlevel10k' instead by setting:
|
||||
zstyle ':prezto:module:prompt' theme 'powerlevel10k'
|
||||
in ~/.zpreztorc.
|
||||
in ${${ZDOTDIR:-$HOME}/#$HOME/~}/.zpreztorc.
|
||||
Switching to prezto default prompt 'sorin'..."
|
||||
EOW
|
||||
prompt 'sorin'
|
||||
|
Reference in New Issue
Block a user