Add xplr segment

This commit is contained in:
Maxim Baz 2021-05-14 22:07:38 +02:00
commit d51c6ddcfb
No known key found for this signature in database
GPG key ID: 011FDC52DA839335
7 changed files with 48 additions and 0 deletions

View file

@ -132,6 +132,7 @@ function _p9k_init_icons() {
LUA_ICON 'lua'
PERL_ICON 'perl'
NNN_ICON 'nnn'
XPLR_ICON 'xplr'
TIMEWARRIOR_ICON 'tw'
TASKWARRIOR_ICON 'task'
NIX_SHELL_ICON 'nix'
@ -260,6 +261,7 @@ function _p9k_init_icons() {
LUA_ICON 'lua'
PERL_ICON 'perl'
NNN_ICON 'nnn'
XPLR_ICON 'xplr'
TIMEWARRIOR_ICON 'tw'
TASKWARRIOR_ICON 'task'
NIX_SHELL_ICON 'nix'
@ -391,6 +393,7 @@ function _p9k_init_icons() {
LUA_ICON 'lua'
PERL_ICON 'perl'
NNN_ICON 'nnn'
XPLR_ICON 'xplr'
TIMEWARRIOR_ICON 'tw'
TASKWARRIOR_ICON 'task'
NIX_SHELL_ICON 'nix'
@ -520,6 +523,7 @@ function _p9k_init_icons() {
LUA_ICON '\uE620' # 
PERL_ICON '\uE769' # 
NNN_ICON 'nnn'
XPLR_ICON 'xplr'
TIMEWARRIOR_ICON '\uF49B' # 
TASKWARRIOR_ICON '\uF4A0 ' # 
NIX_SHELL_ICON '\uF313 ' # 
@ -646,6 +650,7 @@ function _p9k_init_icons() {
LUA_ICON 'lua'
PERL_ICON 'perl'
NNN_ICON 'nnn'
XPLR_ICON 'xplr'
TIMEWARRIOR_ICON 'tw'
TASKWARRIOR_ICON 'task'
NIX_SHELL_ICON 'nix'
@ -774,6 +779,7 @@ function _p9k_init_icons() {
LUA_ICON 'lua'
PERL_ICON 'perl'
NNN_ICON 'nnn'
XPLR_ICON 'xplr'
TIMEWARRIOR_ICON 'tw'
TASKWARRIOR_ICON 'task'
NIX_SHELL_ICON 'nix'

View file

@ -4753,6 +4753,18 @@ function instant_prompt_nnn() {
_p9k_prompt_segment prompt_nnn 6 $_p9k_color1 NNN_ICON 1 '${NNNLVL:#0}' '$NNNLVL'
}
function prompt_xplr() {
_p9k_prompt_segment $0 6 $_p9k_color1 XPLR_ICON 0 '' $XPLR_PID
}
_p9k_prompt_xplr_init() {
typeset -g "_p9k__segment_cond_${_p9k__prompt_side}[_p9k__segment_index]"='$XPLR_PID'
}
function instant_prompt_xplr() {
_p9k_prompt_segment prompt_xplr 6 $_p9k_color1 XPLR_ICON 1 '$XPLR_PID' '$XPLR_PID'
}
function prompt_vim_shell() {
local -i len=$#_p9k__prompt _p9k__has_upglob
_p9k_prompt_segment $0 green $_p9k_color1 VIM_ICON 0 '' ''