aboutsummaryrefslogtreecommitdiff
path: root/config/p10k-pure.zsh
diff options
context:
space:
mode:
authorromkatv <roman.perepelitsa@gmail.com>2020-02-02 08:49:17 +0300
committerromkatv <roman.perepelitsa@gmail.com>2020-02-02 08:49:17 +0300
commit4599ad9f2c6352b5f3ea4cff4305d426cf9e3b31 (patch)
treea518f1b08a440c8ea483b4a3388005669c06b20f /config/p10k-pure.zsh
parenteb9da89ad9a8bd886e43c7f1d907495c5a48acc5 (diff)
add extra options to pure style
- non-permanent content location (left or right) - show current time - prompt height (one or two lines) - prompt spacing (with empty line between prompts or without)
Diffstat (limited to 'config/p10k-pure.zsh')
-rw-r--r--config/p10k-pure.zsh23
1 files changed, 21 insertions, 2 deletions
diff --git a/config/p10k-pure.zsh b/config/p10k-pure.zsh
index 50299dff..8eeaedac 100644
--- a/config/p10k-pure.zsh
+++ b/config/p10k-pure.zsh
@@ -42,17 +42,27 @@
# Left prompt segments.
typeset -g POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(
+ # =========================[ Line #1 ]=========================
dir # current directory
vcs # git status
context # user@host
command_execution_time # previous command duration
+ # =========================[ Line #2 ]=========================
newline # \n
virtualenv # python virtual environment
prompt_char # prompt symbol
)
# Right prompt segments.
- typeset -g POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=()
+ typeset -g POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(
+ # =========================[ Line #1 ]=========================
+ # command_execution_time # previous command duration
+ # virtualenv # python virtual environment
+ # context # user@host
+ # time # current time
+ # =========================[ Line #2 ]=========================
+ newline # \n
+ )
# Basic style options that define the overall prompt look.
typeset -g POWERLEVEL9K_BACKGROUND= # transparent background
@@ -62,7 +72,7 @@
typeset -g POWERLEVEL9K_VISUAL_IDENTIFIER_EXPANSION= # no segment icons
# Add an empty line before each prompt except the first. This doesn't emulate the bug
- # in Pure that makes prompt drift down whenever you use the ALT-C binding from fzf or similar.
+ # in Pure that makes prompt drift down whenever you use the Alt-C binding from fzf or similar.
typeset -g POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
# Magenta prompt symbol if the last command succeeded.
@@ -135,6 +145,15 @@
# Remove space between '⇣' and '⇡' and all trailing spaces.
typeset -g POWERLEVEL9K_VCS_CONTENT_EXPANSION='${${P9K_CONTENT/⇣* ⇡/⇣⇡}// }'
+ # Grey current time.
+ typeset -g POWERLEVEL9K_TIME_FOREGROUND=$grey
+ # Format for the current time: 09:51:02. See `man 3 strftime`.
+ typeset -g POWERLEVEL9K_TIME_FORMAT='%D{%H:%M:%S}'
+ # If set to true, time will update when you hit enter. This way prompts for the past
+ # commands will contain the start times of their commands rather than the end times of
+ # their preceding commands.
+ typeset -g POWERLEVEL9K_TIME_UPDATE_ON_COMMAND=false
+
# Transient prompt works similarly to the builtin transient_rprompt option. It trims down prompt
# when accepting a command line. Supported values:
#