From f12c24e76e708e03f7696cd9e692738c9b285eed Mon Sep 17 00:00:00 2001 From: Sorin Ionescu Date: Mon, 1 Oct 2012 22:02:47 -0400 Subject: [PATCH] Rename python-info zstyle patterns --- modules/prompt/functions/prompt_steeef_setup | 2 +- modules/python/README.md | 2 +- modules/python/functions/python-info | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/prompt/functions/prompt_steeef_setup b/modules/prompt/functions/prompt_steeef_setup index 9b07326..f64f47d 100644 --- a/modules/prompt/functions/prompt_steeef_setup +++ b/modules/prompt/functions/prompt_steeef_setup @@ -82,7 +82,7 @@ function prompt_steeef_setup { zstyle ':vcs_info:*:prompt:*' nvcsformats "" # Set python-info parameters. - zstyle ':prezto:module:python' virtualenv '(%v)' + zstyle ':prezto:module:python:info:virtualenv' format '(%v)' # Define prompts. PROMPT=" diff --git a/modules/python/README.md b/modules/python/README.md index dd6b19a..b94fa32 100644 --- a/modules/python/README.md +++ b/modules/python/README.md @@ -89,7 +89,7 @@ To display the name of the current virtual enviroment in a prompt, define the following style in the `prompt_theme_setup` function. # %v - virtualenv name. - zstyle ':prezto:module:python' virtualenv 'virtualenv:%v' + zstyle ':prezto:module:python:info:virtualenv' format 'virtualenv:%v' Then add `$python_info[virtualenv]` to `$PROMPT` or `$RPROMPT` and call `python-info` in the `prompt_theme_preexec` hook function. diff --git a/modules/python/functions/python-info b/modules/python/functions/python-info index 40c5011..634d01d 100644 --- a/modules/python/functions/python-info +++ b/modules/python/functions/python-info @@ -15,7 +15,7 @@ typeset -gA python_info # Format virtualenv. if [[ -n "$VIRTUAL_ENV" ]]; then - zstyle -s ':prezto:module:python' virtualenv 'virtualenv_format' + zstyle -s ':prezto:module:python:info:virtualenv' format 'virtualenv_format' zformat -f virtualenv_formatted "$virtualenv_format" "v:${VIRTUAL_ENV:t}" python_info[virtualenv]="$virtualenv_formatted" fi