Reorganized zshrc to shared components
This commit is contained in:
parent
fe61b390d6
commit
2993323384
4 changed files with 38 additions and 48 deletions
8
.local/dotfiles/environment/core.zsh
Normal file
8
.local/dotfiles/environment/core.zsh
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
# Default Environment
|
||||||
|
export EDITOR=vim
|
||||||
|
export VISUAL=vim
|
||||||
|
export PAGER=less
|
||||||
|
|
||||||
|
# Disable Ctrl+S Scroll-Locking
|
||||||
|
stty -ixon
|
||||||
|
|
4
.local/dotfiles/environment/esc-backspace.zsh
Normal file
4
.local/dotfiles/environment/esc-backspace.zsh
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
# Fix the ESC+Backspace
|
||||||
|
bindkey -e "^[[1;5C" forward-word
|
||||||
|
bindkey -e "^[[1;5D" backward-word
|
||||||
|
|
23
.local/dotfiles/environment/vte.zsh
Normal file
23
.local/dotfiles/environment/vte.zsh
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
if [[ -f /etc/solus-release ]]; then
|
||||||
|
export SSH_ASKPASS=/usr/lib64/seahorse/seahorse/ssh-askpass
|
||||||
|
|
||||||
|
if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
||||||
|
source /usr/share/defaults/etc/profile.d/vte.sh
|
||||||
|
precmd_functions+=(__vte_osc7)
|
||||||
|
fi
|
||||||
|
elif [[ -f /etc/debian_version ]]; then
|
||||||
|
if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
||||||
|
if [[ -r "/etc/profile.d/vte-2.91.sh" ]]; then
|
||||||
|
source /etc/profile.d/vte-2.91.sh
|
||||||
|
precmd_functions+=(__vte_osc7)
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
elif [[ -f /etc/fedora-release ]]; then
|
||||||
|
if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
||||||
|
if [[ -r "/etc/profile.d/vte.sh" ]]; then
|
||||||
|
source /etc/profile.d/vte.sh
|
||||||
|
precmd_functions+=(__vte_osc7)
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
51
.zshrc
51
.zshrc
|
@ -1,12 +1,3 @@
|
||||||
#if [[ -f /etc/solus-release ]]; then
|
|
||||||
# if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
|
||||||
# echo "Loading VTE extensions..."
|
|
||||||
# source /usr/share/defaults/etc/profile.d/vte.sh
|
|
||||||
# fi
|
|
||||||
#fi
|
|
||||||
#precmd_functions+=(__vte_osc7)
|
|
||||||
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# User configuration sourced by interactive shells
|
# User configuration sourced by interactive shells
|
||||||
#
|
#
|
||||||
|
@ -21,42 +12,9 @@ export ZIM_HOME=${ZDOTDIR:-${HOME}}/.zim
|
||||||
[[ -s ${ZIM_HOME}/init.zsh ]] && source ${ZIM_HOME}/init.zsh
|
[[ -s ${ZIM_HOME}/init.zsh ]] && source ${ZIM_HOME}/init.zsh
|
||||||
|
|
||||||
# Fix the ESC+Backspace
|
# Fix the ESC+Backspace
|
||||||
bindkey -e
|
#bindkey -e
|
||||||
bindkey -e "^[[1;5C" forward-word
|
#bindkey -e "^[[1;5C" forward-word
|
||||||
bindkey -e "^[[1;5D" backward-word
|
#bindkey -e "^[[1;5D" backward-word
|
||||||
|
|
||||||
# Default Environment
|
|
||||||
export EDITOR=vim
|
|
||||||
export VISUAL=vim
|
|
||||||
export PAGER=less
|
|
||||||
|
|
||||||
#function custom_prompt() {
|
|
||||||
# VTE_PWD_THING="$(__vte_osc7)"
|
|
||||||
# PS1="$PS1$VTE_PWD_THING"
|
|
||||||
#}
|
|
||||||
|
|
||||||
if [[ -f /etc/solus-release ]]; then
|
|
||||||
export SSH_ASKPASS=/usr/lib64/seahorse/seahorse/ssh-askpass
|
|
||||||
|
|
||||||
if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
|
||||||
source /usr/share/defaults/etc/profile.d/vte.sh
|
|
||||||
precmd_functions+=(__vte_osc7)
|
|
||||||
fi
|
|
||||||
elif [[ -f /etc/debian_version ]]; then
|
|
||||||
if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
|
||||||
if [[ -r "/etc/profile.d/vte-2.91.sh" ]]; then
|
|
||||||
source /etc/profile.d/vte-2.91.sh
|
|
||||||
precmd_functions+=(__vte_osc7)
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
elif [[ -f /etc/fedora-release ]]; then
|
|
||||||
if [[ $TILIX_ID || $VTE_VERSION ]]; then
|
|
||||||
if [[ -r "/etc/profile.d/vte.sh" ]]; then
|
|
||||||
source /etc/profile.d/vte.sh
|
|
||||||
precmd_functions+=(__vte_osc7)
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Set GPG TTY
|
# Set GPG TTY
|
||||||
#export GPG_TTY=$(tty)
|
#export GPG_TTY=$(tty)
|
||||||
|
@ -70,9 +28,6 @@ fi
|
||||||
# export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
# export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||||
#fi
|
#fi
|
||||||
|
|
||||||
# Disable Ctrl+S Scroll-Locking
|
|
||||||
stty -ixon
|
|
||||||
|
|
||||||
# Include local functions/aliases/environments:
|
# Include local functions/aliases/environments:
|
||||||
while read f
|
while read f
|
||||||
do
|
do
|
||||||
|
|
Loading…
Reference in a new issue