optimized PZT

This commit is contained in:
Stefen Auris 2021-06-02 22:01:15 -04:00
parent 5631c6d58c
commit c2ff40d004
2 changed files with 89 additions and 26 deletions

64
zsh/.zprofile Normal file
View file

@ -0,0 +1,64 @@
#
# Executes commands at login pre-zshrc.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
#
# Browser
#
if [[ "$OSTYPE" == darwin* ]]; then
export BROWSER='open'
fi
#
# Editors
#
export EDITOR='vim'
export VISUAL='vim'
export PAGER='less'
#
# Language
#
if [[ -z "$LANG" ]]; then
export LANG='en_US.UTF-8'
fi
#
# Paths
#
# Ensure path arrays do not contain duplicates.
typeset -gU cdpath fpath mailpath path
# Set the list of directories that cd searches.
# cdpath=(
# $cdpath
# )
# Set the list of directories that Zsh searches for programs.
path=(
/usr/local/{bin,sbin}
$path
)
#
# Less
#
# Set the default Less options.
# Mouse-wheel scrolling has been disabled by -X (disable screen clearing).
# Remove -X to enable it.
export LESS='-g -i -M -R -S -w -z-4'
# Set the Less input preprocessor.
# Try both `lesspipe` and `lesspipe.sh` as either might exist on a system.
if (( $#commands[(i)lesspipe(|.sh)] )); then
export LESSOPEN="| /usr/bin/env $commands[(i)lesspipe(|.sh)] %s 2>&-"
fi

View file

@ -30,6 +30,30 @@ zinit ice depth=1; zinit light romkatv/powerlevel10k
# Uncomment following line if you want red dots to be displayed while waiting for completion
export COMPLETION_WAITING_DOTS="true"
#####################
# PREZTO
#####################
zstyle ':prezto:*:*' case-sensitive 'no'
zstyle ':prezto:*:*' color 'yes'
zinit ice silent; zinit snippet PZT::modules/gpg
zstyle :omz:plugins:ssh-agent identities id_rsa github_rsa pete_rsa stevserver_rsa ymca_rsa
# Auto convert .... to ../..
zstyle ':prezto:module:editor' dot-expansion 'yes'
zinit wait lucid for \
OMZ::plugins/common-aliases \
if"[[ $+commands[systemd] ]]" OMZ::plugins/systemd \
hkupty/ssh-agent \
PZT::modules/helper/init.zsh \
PZT::modules/environment/init.zsh \
PZT::modules/terminal/init.zsh \
PZT::modules/editor/init.zsh \
PZT::modules/history/init.zsh \
PZT::modules/directory/init.zsh \
PZT::modules/spectrum/init.zsh
# PZT::modules/utility/init.zsh
#####################
# PLUGINS #
#####################
@ -39,15 +63,6 @@ zstyle ':prezto:module:tmux:session' name 'λ'
zstyle ':prezto:module:tmux:auto-start' remote 'yes'
zinit ice zinit snippet PZT::modules/tmux
# }}}
# prezto {{{
zstyle ':prezto:*:*' case-sensitive 'no'
zstyle ':prezto:*:*' color 'yes'
zinit ice zinit snippet PZT::modules/editor
zinit ice silent; zinit snippet PZT::modules/gpg
zinit ice silent pick"init.zsh" lucid; zinit snippet PZT::modules/utility
zstyle :omz:plugins:ssh-agent identities id_rsa github_rsa pete_rsa stevserver_rsa ymca_rsa
# }}}
##Set VI MODE
bindkey -v
bindkey '^r' history-incremental-search-backward
@ -198,15 +213,10 @@ unsetopt CHECK_JOBS # Don't report on jobs when shell exit.
#####################
# ENV VARIABLE #
#####################
#export EDITOR='nvim'
export EDITOR='vim'
export VISUAL=$EDITOR
export PAGER='less'
#export SHELL='/bin/zsh'
# if [[ ! $(tmux ls) ]] 2> /dev/null; then
# tmux new -s λ
# fi
#####################
# COLORING #
#####################
@ -216,18 +226,7 @@ autoload colors && colors
# ALIASES #
#####################
source $HOME/.zsh_aliases
zinit wait lucid for \
OMZ::plugins/common-aliases \
if"[[ $+commands[systemd] ]]" OMZ::plugins/systemd \
PZT::modules/directory/init.zsh \
PZT::modules/tmux \
hkupty/ssh-agent \
PZT::modules/helper \
PZT::modules/environment \
PZT::modules/terminal \
PZT::modules/spectrum \
PZT::modules/history \
PZT::modules/directory \
#####################
# FANCY-CTRL-Z #
#####################