From 34482cb325cfe8521f9dd462e956faf14d2d0ad8 Mon Sep 17 00:00:00 2001 From: Kaleb Elwert Date: Wed, 6 Sep 2017 11:18:09 -0700 Subject: [PATCH] prompt: add documentation for return value display --- modules/prompt/README.md | 9 +++++++++ runcoms/zpreztorc | 4 ++++ 2 files changed, 13 insertions(+) diff --git a/modules/prompt/README.md b/modules/prompt/README.md index f272f27..4f9fd82 100644 --- a/modules/prompt/README.md +++ b/modules/prompt/README.md @@ -26,6 +26,15 @@ in *zpreztorc*. zstyle ':prezto:module:prompt' pwd-length 'short' ``` +### Display Return Value + +Some prompts display the return value in the prompt. If a prompt has support, +this can be disabled with the following snippet. + +```sh +zstyle ':prezto:module:prompt' show-return-val 'no' +``` + Theming ------- diff --git a/runcoms/zpreztorc b/runcoms/zpreztorc index 0b7a837..cd92317 100644 --- a/runcoms/zpreztorc +++ b/runcoms/zpreztorc @@ -117,6 +117,10 @@ zstyle ':prezto:module:prompt' theme 'sorin' # for longer or 'full' (with '~' expansion) for even longer prompt display. # zstyle ':prezto:module:prompt' pwd-length 'short' +# Set the prompt to display the return code along with an indicator for non-zero +# return codes. This is not supported by all prompts. +# zstyle ':prezto:module:prompt' show-return-val 'yes' + # # Ruby #