2020-04-05 22:18:15 +00:00
|
|
|
|
typeset -g HISTFILE=~/.histfile
|
2020-05-21 20:31:48 +00:00
|
|
|
|
typeset -g CACHEPATH=/tmp
|
2020-04-05 22:18:15 +00:00
|
|
|
|
typeset -g HISTSIZE=1000
|
|
|
|
|
typeset -g SAVEHIST=1000
|
|
|
|
|
typeset -g ZLE_RPROMPT_INDENT=0
|
2020-05-03 11:56:52 +00:00
|
|
|
|
setopt appendhistory autocd auto_pushd extendedglob nomatch notify hist_ignore_all_dups hist_ignore_space nobeep
|
2019-12-18 18:31:56 +00:00
|
|
|
|
|
2020-05-22 12:56:46 +00:00
|
|
|
|
|
2020-05-19 12:11:34 +00:00
|
|
|
|
if [[ $_set_prompt == "p9k" ]]; then
|
2020-04-05 22:18:15 +00:00
|
|
|
|
source ${ZDOTDIR}/powerlevel10k/powerlevel10k.zsh-theme
|
2020-05-22 12:56:46 +00:00
|
|
|
|
|
|
|
|
|
typeset -g POWERLEVEL9K_DISABLE_HOT_RELOAD=true
|
|
|
|
|
typeset -g POWERLEVEL9K_MODE=nerdfont-complete
|
|
|
|
|
typeset -g POWERLEVEL9K_ICON_PADDING=none
|
|
|
|
|
|
|
|
|
|
# Separators
|
|
|
|
|
typeset -g POWERLEVEL9K_LEFT_SUBSEGMENT_SEPARATOR='\uE0BD'
|
|
|
|
|
typeset -g POWERLEVEL9K_RIGHT_SUBSEGMENT_SEPARATOR='\uE0BD'
|
|
|
|
|
typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR='\uE0BC'
|
|
|
|
|
typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR='\uE0BA'
|
|
|
|
|
typeset -g POWERLEVEL9K_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL='\uE0B0'
|
|
|
|
|
typeset -g POWERLEVEL9K_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL='\uE0B2'
|
|
|
|
|
typeset -g POWERLEVEL9K_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL=''
|
|
|
|
|
typeset -g POWERLEVEL9K_RIGHT_PROMPT_LAST_SEGMENT_END_SYMBOL=''
|
|
|
|
|
typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL=
|
|
|
|
|
|
|
|
|
|
# Prompt
|
|
|
|
|
typeset -g POWERLEVEL9K_PROMPT_CHAR_OK_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=76
|
|
|
|
|
typeset -g POWERLEVEL9K_PROMPT_CHAR_ERROR_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=196
|
|
|
|
|
typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIINS_CONTENT_EXPANSION='❯'
|
|
|
|
|
|
|
|
|
|
# Directory
|
|
|
|
|
typeset -g POWERLEVEL9K_SHORTEN_STRATEGY=truncate_to_unique
|
|
|
|
|
typeset -g POWERLEVEL9K_DIR_TRUNCATE_BEFORE_MARKER=true
|
|
|
|
|
typeset -g POWERLEVEL9K_DIR_MAX_LENGTH='50%'
|
|
|
|
|
typeset -g POWERLEVEL9K_SHORTEN_FOLDER_MARKER="(${(j:|:)anchor_files})"
|
|
|
|
|
typeset -g POWERLEVEL9K_DIR_SHOW_WRITABLE=true
|
|
|
|
|
|
|
|
|
|
# Status
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_EXTENDED_STATES=true
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_OK=false
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_OK_PIPE=true
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_OK_PIPE_VISUAL_IDENTIFIER_EXPANSION='✔'
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_ERROR=true
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_ERROR_VISUAL_IDENTIFIER_EXPANSION='✘'
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL=true
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_VERBOSE_SIGNAME=false
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_VISUAL_IDENTIFIER_EXPANSION='✘'
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE=true
|
|
|
|
|
typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE_VISUAL_IDENTIFIER_EXPANSION='✘'
|
|
|
|
|
|
|
|
|
|
# Execution time
|
|
|
|
|
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FOREGROUND=0
|
|
|
|
|
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_BACKGROUND=3
|
|
|
|
|
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=3
|
|
|
|
|
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION=0
|
|
|
|
|
typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FORMAT='d h m s'
|
|
|
|
|
|
|
|
|
|
# Disk usage
|
|
|
|
|
typeset -g POWERLEVEL9K_DISK_USAGE_WARNING_LEVEL=90
|
|
|
|
|
typeset -g POWERLEVEL9K_DISK_USAGE_CRITICAL_LEVEL=95
|
|
|
|
|
|
|
|
|
|
# vi mode
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_MODE_FOREGROUND=0
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_COMMAND_MODE_STRING=NORMAL
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_MODE_NORMAL_BACKGROUND=2
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_VISUAL_MODE_STRING=VISUAL
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_MODE_VISUAL_BACKGROUND=4
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_OVERWRITE_MODE_STRING=OVERTYPE
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_MODE_OVERWRITE_BACKGROUND=3
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_INSERT_MODE_STRING=
|
|
|
|
|
typeset -g POWERLEVEL9K_VI_MODE_INSERT_FOREGROUND=8
|
|
|
|
|
|
|
|
|
|
# Context
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_ROOT_FOREGROUND=1
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_ROOT_BACKGROUND=0
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_FOREGROUND=3
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_BACKGROUND=0
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_FOREGROUND=3
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_BACKGROUND=0
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_ROOT_TEMPLATE='%n@%m'
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_TEMPLATE='%n@%m'
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_TEMPLATE='%n@%m'
|
|
|
|
|
typeset -g POWERLEVEL9K_CONTEXT_{DEFAULT,SUDO}_{CONTENT,VISUAL_IDENTIFIER}_EXPANSION=
|
|
|
|
|
|
|
|
|
|
# Time
|
|
|
|
|
typeset -g POWERLEVEL9K_TIME_UPDATE_ON_COMMAND=true
|
|
|
|
|
|
|
|
|
|
# Caching
|
|
|
|
|
typeset -g POWERLEVEL9K_USE_CACHE=true
|
|
|
|
|
|
|
|
|
|
# Transient Prompt
|
|
|
|
|
typeset -g POWERLEVEL9K_TRANSIENT_PROMPT=same-dir
|
|
|
|
|
typeset -g POWERLEVEL9K_INSTANT_PROMPT=quiet
|
|
|
|
|
|
|
|
|
|
local anchor_files=(
|
|
|
|
|
.git
|
|
|
|
|
Dockerfile
|
|
|
|
|
main.yml
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
# Prompt elements
|
2020-04-05 22:18:15 +00:00
|
|
|
|
typeset -g POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(
|
|
|
|
|
os_icon
|
|
|
|
|
time
|
|
|
|
|
battery
|
|
|
|
|
disk_usage
|
|
|
|
|
ssh
|
|
|
|
|
root_indicator
|
|
|
|
|
newline
|
|
|
|
|
vi_mode
|
|
|
|
|
status
|
|
|
|
|
dir
|
|
|
|
|
dir_writable
|
|
|
|
|
)
|
|
|
|
|
typeset -g POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(
|
|
|
|
|
command_execution_time
|
|
|
|
|
background_jobs
|
|
|
|
|
vim_shell
|
|
|
|
|
new_mail
|
2020-05-21 20:31:48 +00:00
|
|
|
|
mpv_mpris
|
2020-05-19 12:11:34 +00:00
|
|
|
|
weather
|
2020-04-14 18:09:10 +00:00
|
|
|
|
covid_19
|
2020-04-14 18:54:54 +00:00
|
|
|
|
public_ip
|
|
|
|
|
newline
|
|
|
|
|
docker_host
|
2020-04-05 22:18:15 +00:00
|
|
|
|
vcs
|
|
|
|
|
)
|
2019-12-18 18:31:56 +00:00
|
|
|
|
else
|
2020-04-05 22:18:15 +00:00
|
|
|
|
export TERM="xterm";
|
|
|
|
|
autoload -Uz promptinit
|
|
|
|
|
promptinit
|
|
|
|
|
prompt clint
|
2019-12-18 18:31:56 +00:00
|
|
|
|
fi
|
|
|
|
|
|
2020-04-07 13:45:08 +00:00
|
|
|
|
source ${ZDOTDIR}/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
2020-04-05 22:18:15 +00:00
|
|
|
|
typeset -g ZSH_HIGHLIGHT_HIGHLIGHTERS=(
|
|
|
|
|
main
|
|
|
|
|
brackets
|
|
|
|
|
pattern
|
|
|
|
|
cursor
|
|
|
|
|
)
|
2019-12-18 18:31:56 +00:00
|
|
|
|
|
2019-12-31 21:02:41 +00:00
|
|
|
|
source ${ZDOTDIR}/zsh-autosuggestions/zsh-autosuggestions.zsh
|
2020-04-05 22:18:15 +00:00
|
|
|
|
typeset -g ZSH_AUTOSUGGEST_STRATEGY=(history completion)
|
|
|
|
|
typeset -g ZSH_AUTOSUGGEST_USE_ASYNC=true
|