diff --git a/.github/ISSUE_TEMPLATE/request-to-add-zshrc.md b/.github/ISSUE_TEMPLATE/request-to-add-zshrc.md index 86f1820..93bbe55 100644 --- a/.github/ISSUE_TEMPLATE/request-to-add-zshrc.md +++ b/.github/ISSUE_TEMPLATE/request-to-add-zshrc.md @@ -1,14 +1,10 @@ - - - - [URL](#url) - [Username](#username) - [Zshrc body](#zshrc-body) - - --- -name: Request to add zshrc to the zplugin-configs repo + +name: Request to add zshrc to the playground repo about: Use this to submit a zshrc to the repo title: '' labels: '' diff --git a/Dockerfile b/Dockerfile index 26b27d8..d55cfd4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,11 +2,9 @@ FROM ubuntu:impish-20211102 # Update && install common dependencies ARG DEBIAN_FRONTEND=noninteractive -RUN apt update && \ - apt install -yq \ +RUN apt update && apt install -yq \ ncurses-dev man telnet unzip zsh git subversion curl make sudo locales \ - autoconf automake python golang-go \ - vim htop + autoconf automake python3 golang-go vim htop # Set the locale RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && locale-gen @@ -22,7 +20,7 @@ RUN adduser --disabled-password --gecos '' user && \ USER user # Install -RUN sh -c "$(curl -fsSL https://raw.githubusercontent.com/ss-o/zi-src/main/lib/sh/install.sh)" +RUN bash <(curl -fsSL https://raw.githubusercontent.com/z-shell/zi-src/main/lib/sh/install.sh) # Copy configs into home directory ARG FOLDER @@ -43,6 +41,6 @@ RUN if [ -f /home/user/bootstrap.sh ]; then \ # Install all plugins ARG TERM ENV TERM ${TERM} -RUN SHELL=/bin/zsh zsh -i -c -- 'zi module build; @zi-scheduler burst || true ' +RUN SHELL=/bin/zsh zsh -i -c -- '@zi-scheduler burst || true ' CMD zsh -i -l diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/LICENSE b/NICHOLAS85/.zi/plugins/_local---config-files/LICENSE similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/LICENSE rename to NICHOLAS85/.zi/plugins/_local---config-files/LICENSE diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/README.md b/NICHOLAS85/.zi/plugins/_local---config-files/README.md similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/README.md rename to NICHOLAS85/.zi/plugins/_local---config-files/README.md diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_clight b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_clight similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_clight rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_clight diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_colorls b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_colorls similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_colorls rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_colorls diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_dynamicwall b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_dynamicwall similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_dynamicwall rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_dynamicwall diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_gebaard b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_gebaard similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_gebaard rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_gebaard diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_groff b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_groff similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_groff rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_groff diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_nl b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_nl similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_nl rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_nl diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/_tlp-stat b/NICHOLAS85/.zi/plugins/_local---config-files/completions/_tlp-stat similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/_tlp-stat rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/_tlp-stat diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/completions/err_ggrep b/NICHOLAS85/.zi/plugins/_local---config-files/completions/err_ggrep similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/completions/err_ggrep rename to NICHOLAS85/.zi/plugins/_local---config-files/completions/err_ggrep diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/config-files.plugin.zsh b/NICHOLAS85/.zi/plugins/_local---config-files/config-files.plugin.zsh similarity index 98% rename from NICHOLAS85/.zinit/plugins/_local---config-files/config-files.plugin.zsh rename to NICHOLAS85/.zi/plugins/_local---config-files/config-files.plugin.zsh index af2a925..e874921 100644 --- a/NICHOLAS85/.zinit/plugins/_local---config-files/config-files.plugin.zsh +++ b/NICHOLAS85/.zi/plugins/_local---config-files/config-files.plugin.zsh @@ -1,7 +1,7 @@ #Let Atom highlight this: -*- shell-script -*- # According to the Zsh Plugin Standard: -# http://zdharma.org/Zsh-100-Commits-Club/Zsh-Plugin-Standard.html +# https://github.com/z-shell/zi/wiki/Zsh-Plugin-Standard 0="${${ZERO:-${0:#$ZSH_ARGZERO}}:-${(%):-%N}}" 0="${${(M)0:#/*}:-$PWD/$0}" diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/apt-history b/NICHOLAS85/.zi/plugins/_local---config-files/functions/apt-history similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/apt-history rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/apt-history diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/autoenv-files b/NICHOLAS85/.zi/plugins/_local---config-files/functions/autoenv-files similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/autoenv-files rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/autoenv-files diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/chpwd_ls b/NICHOLAS85/.zi/plugins/_local---config-files/functions/chpwd_ls similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/chpwd_ls rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/chpwd_ls diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/dotscheck b/NICHOLAS85/.zi/plugins/_local---config-files/functions/dotscheck similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/dotscheck rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/dotscheck diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/history-stat b/NICHOLAS85/.zi/plugins/_local---config-files/functions/history-stat similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/history-stat rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/history-stat diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/kate b/NICHOLAS85/.zi/plugins/_local---config-files/functions/kate similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/kate rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/kate diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/mcsvr b/NICHOLAS85/.zi/plugins/_local---config-files/functions/mcsvr similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/mcsvr rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/mcsvr diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/sudo b/NICHOLAS85/.zi/plugins/_local---config-files/functions/sudo similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/sudo rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/sudo diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/whichedit b/NICHOLAS85/.zi/plugins/_local---config-files/functions/whichedit similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/functions/whichedit rename to NICHOLAS85/.zi/plugins/_local---config-files/functions/whichedit diff --git a/NICHOLAS85/.zi/plugins/_local---config-files/functions/zicompinit_fast b/NICHOLAS85/.zi/plugins/_local---config-files/functions/zicompinit_fast new file mode 100644 index 0000000..2396315 --- /dev/null +++ b/NICHOLAS85/.zi/plugins/_local---config-files/functions/zicompinit_fast @@ -0,0 +1,22 @@ +setopt extendedglob local_options +autoload -Uz compinit +local zcompf="${ZI[ZCOMPDUMP_PATH]:-${ZDOTDIR:-$HOME}/.zcompdump}" + +# use a separate file to determine when to regenerate, as compinit doesn't always need to modify the compdump +local zcompf_a="${zcompf}.augur" + +if [[ -e "$zcompf_a" && -f "$zcompf_a"(#qN.mh+24) ]]; then + compinit -d "$zcompf" + touch "$zcompf_a" +else + compinit -C -d "$zcompf" +fi + +# if zcompdump exists (and is non-zero), and is older than the .zwc file, then regenerate +if [[ -s "$zcompf" && (! -s "${zcompf}.zwc" || "$zcompf" -nt "${zcompf}.zwc") ]]; then + # since file is mapped, it might be mapped right now (current shells), so rename it then make a new one + [[ -e "$zcompf.zwc" ]] && mv -f "$zcompf.zwc" "$zcompf.zwc.old" + # compile it mapped, so multiple shells can share it (total mem reduction) + # run in background + { zcompile -M "$zcompf" && command rm -f "$zcompf.zwc.old" }&! +fi diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/patches/LS_COLORS.patch b/NICHOLAS85/.zi/plugins/_local---config-files/patches/LS_COLORS.patch similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/patches/LS_COLORS.patch rename to NICHOLAS85/.zi/plugins/_local---config-files/patches/LS_COLORS.patch diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/patches/fz.patch b/NICHOLAS85/.zi/plugins/_local---config-files/patches/fz.patch similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/patches/fz.patch rename to NICHOLAS85/.zi/plugins/_local---config-files/patches/fz.patch diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/patches/rm-trash.patch b/NICHOLAS85/.zi/plugins/_local---config-files/patches/rm-trash.patch similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/patches/rm-trash.patch rename to NICHOLAS85/.zi/plugins/_local---config-files/patches/rm-trash.patch diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/patches/zsh-dircycle.patch b/NICHOLAS85/.zi/plugins/_local---config-files/patches/zsh-dircycle.patch similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/patches/zsh-dircycle.patch rename to NICHOLAS85/.zi/plugins/_local---config-files/patches/zsh-dircycle.patch diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/themes/dolphin-post.zsh b/NICHOLAS85/.zi/plugins/_local---config-files/themes/dolphin-post.zsh similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/themes/dolphin-post.zsh rename to NICHOLAS85/.zi/plugins/_local---config-files/themes/dolphin-post.zsh diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/themes/p10k-post.zsh b/NICHOLAS85/.zi/plugins/_local---config-files/themes/p10k-post.zsh similarity index 100% rename from NICHOLAS85/.zinit/plugins/_local---config-files/themes/p10k-post.zsh rename to NICHOLAS85/.zi/plugins/_local---config-files/themes/p10k-post.zsh diff --git a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/zicompinit_fast b/NICHOLAS85/.zinit/plugins/_local---config-files/functions/zicompinit_fast deleted file mode 100644 index fd14fa8..0000000 --- a/NICHOLAS85/.zinit/plugins/_local---config-files/functions/zicompinit_fast +++ /dev/null @@ -1,22 +0,0 @@ -setopt extendedglob local_options -autoload -Uz compinit -local zcompf="${ZINIT[ZCOMPDUMP_PATH]:-${ZDOTDIR:-$HOME}/.zcompdump}" - -# use a separate file to determine when to regenerate, as compinit doesn't always need to modify the compdump -local zcompf_a="${zcompf}.augur" - -if [[ -e "$zcompf_a" && -f "$zcompf_a"(#qN.mh+24) ]]; then - compinit -d "$zcompf" - touch "$zcompf_a" -else - compinit -C -d "$zcompf" -fi - -# if zcompdump exists (and is non-zero), and is older than the .zwc file, then regenerate -if [[ -s "$zcompf" && (! -s "${zcompf}.zwc" || "$zcompf" -nt "${zcompf}.zwc") ]]; then - # since file is mapped, it might be mapped right now (current shells), so rename it then make a new one - [[ -e "$zcompf.zwc" ]] && mv -f "$zcompf.zwc" "$zcompf.zwc.old" - # compile it mapped, so multiple shells can share it (total mem reduction) - # run in background - { zcompile -M "$zcompf" && command rm -f "$zcompf.zwc.old" }&! -fi diff --git a/NICHOLAS85/.zshrc b/NICHOLAS85/.zshrc index e2da149..85bd2e1 100644 --- a/NICHOLAS85/.zshrc +++ b/NICHOLAS85/.zshrc @@ -2,19 +2,19 @@ # Used to programatically disable plugins when opening the terminal view in dolphin if [[ $MYPROMPT = dolphin ]]; then - isdolphin=true + isdolphin=true else - isdolphin=false - autoload -Uz chpwd_recent_dirs add-zsh-hook - add-zsh-hook chpwd chpwd_recent_dirs - zstyle ':chpwd:*' recent-dirs-file "$TMPDIR/chpwd-recent-dirs" - (){ - local chpwdrdf - zstyle -g chpwdrdf ':chpwd:*' recent-dirs-file - dirstack=($(awk -F"'" '{print $2}' "$chpwdrdf" 2>/dev/null)) - [[ $PWD = ~ ]] && { cd ${dirstack[1]} 2>/dev/null || true } - dirstack=("${dirstack[@]:1}") - } + isdolphin=false + autoload -Uz chpwd_recent_dirs add-zsh-hook + add-zsh-hook chpwd chpwd_recent_dirs + zstyle ':chpwd:*' recent-dirs-file "$TMPDIR/chpwd-recent-dirs" + (){ + local chpwdrdf + zstyle -g chpwdrdf ':chpwd:*' recent-dirs-file + dirstack=($(awk -F"'" '{print $2}' "$chpwdrdf" 2>/dev/null)) + [[ $PWD = ~ ]] && { cd ${dirstack[1]} 2>/dev/null || true } + dirstack=("${dirstack[@]:1}") + } fi # Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. @@ -24,42 +24,39 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]] source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" fi -ZINIT_HOME="${ZINIT_HOME:-${ZPLG_HOME:-${ZDOTDIR:-$HOME}/.zinit}}" -ZINIT_BIN_DIR_NAME="${${ZINIT_BIN_DIR_NAME:-$ZPLG_BIN_DIR_NAME}:-bin}" -### Added by Zinit's installer -if [[ ! -f $ZINIT_HOME/$ZINIT_BIN_DIR_NAME/zinit.zsh ]]; then - print -P "%F{33}▓▒░ %F{220}Installing DHARMA Initiative Plugin Manager (zdharma/zinit)…%f" - command mkdir -p "$ZINIT_HOME" && command chmod g-rwX "$ZINIT_HOME" - command git clone https://github.com/zdharma/zinit "$ZINIT_HOME/$ZINIT_BIN_DIR_NAME" && \ - print -P "%F{33}▓▒░ %F{34}Installation successful.%f" || \ - print -P "%F{160}▓▒░ The clone has failed.%f" +ZI_HOME="${ZI_HOME:-${ZPLG_HOME:-${ZDOTDIR:-$HOME}/.zi}}" +ZI_BIN_DIR_NAME="${${ZI_BIN_DIR_NAME:-$ZPLG_BIN_DIR_NAME}:-bin}" +### Added by ZI's installer +if [[ ! -f $ZI_HOME/$ZI_BIN_DIR_NAME/zi.zsh ]]; then + print -P "%F{33}▓▒░ %F{220}Installing ZI Initiative Plugin Manager (z-shell/zi)…%f" + command mkdir -p "$ZI_HOME" && command chmod g-rwX "$ZI_HOME" + command git clone https://github.com/z-shell/zi "$ZI_HOME/$ZI_BIN_DIR_NAME" && \ + print -P "%F{33}▓▒░ %F{34}Installation successful.%f" || \ + print -P "%F{160}▓▒░ The clone has failed.%f" fi -source "$ZINIT_HOME/$ZINIT_BIN_DIR_NAME/zinit.zsh" -autoload -Uz _zinit -(( ${+_comps} )) && _comps[zinit]=_zinit -### End of Zinit installer's chunk - -#module_path+=( "${HOME}/.zinit/bin/zmodules/Src" ) -#zmodload zdharma/zplugin &>/dev/null - -if [[ ! -d "${ZINIT[PLUGINS_DIR]}/_local---config-files" ]]; then - print -P "%F{33}▓▒░ %F{220}Installing local config-files…%f" - curl https://codeload.github.com/NICHOLAS85/dotfiles/tar.gz/xps_13_9365_refresh | \ - tar -xz --strip=3 dotfiles-xps_13_9365/.zinit/plugins/_local---config-files - mv _local---config-files "${ZINIT[PLUGINS_DIR]}/" +source "$ZI_HOME/$ZI_BIN_DIR_NAME/zi.zsh" +autoload -Uz _zi +(( ${+_comps} )) && _comps[zi]=_zi +### End of ZI installer's chunk + +if [[ ! -d "${ZI[PLUGINS_DIR]}/_local---config-files" ]]; then + print -P "%F{33}▓▒░ %F{220}Installing local config-files…%f" + curl https://codeload.github.com/NICHOLAS85/dotfiles/tar.gz/xps_13_9365_refresh | \ + tar -xz --strip=3 dotfiles-xps_13_9365/.zi/plugins/_local---config-files + mv _local---config-files "${ZI[PLUGINS_DIR]}/" fi # Functions to make configuration less verbose # zt() : First argument is a wait time and suffix, ie "0a". Anything that doesn't match will be passed as if it were an ice mod. Default ices depth'3' and lucid # zct(): First argument provides $MYPROMPT value used in load'' and unload'' ices. Sources a config file with tracking for easy unloading using $MYPROMPT value. Small hack to function in for-syntax -zt() { zinit depth'3' lucid ${1/#[0-9][a-c]/wait"$1"} "${@:2}"; } +zt() { zi depth'3' lucid ${1/#[0-9][a-c]/wait"$1"} "${@:2}"; } zct() { - thmf="${ZINIT[PLUGINS_DIR]}/_local---config-files/themes" - if [[ ${1} != ${MYPROMPT=p10k} ]] && { ___turbo=1; .zinit-ice \ - load"[[ \${MYPROMPT} = ${1} ]]" unload"[[ \${MYPROMPT} != ${1} ]]" } - .zinit-ice atload'! [[ -f "${thmf}/${MYPROMPT}-post.zsh" ]] && source "${thmf}/${MYPROMPT}-post.zsh"' \ - nocd id-as"${1}-theme"; - ICE+=("${(kv)ZINIT_ICES[@]}"); ZINIT_ICES=(); + thmf="${ZI[PLUGINS_DIR]}/_local---config-files/themes" + if [[ ${1} != ${MYPROMPT=p10k} ]] && { ___turbo=1; .zi-ice \ + load"[[ \${MYPROMPT} = ${1} ]]" unload"[[ \${MYPROMPT} != ${1} ]]" } + .zi-ice atload'! [[ -f "${thmf}/${MYPROMPT}-post.zsh" ]] && source "${thmf}/${MYPROMPT}-post.zsh"' \ + nocd id-as"${1}-theme"; + ICE+=("${(kv)ZI_ICES[@]}"); ZI_ICES=(); } ################## @@ -69,122 +66,122 @@ zct() { ################## zt light-mode for \ - pick'async.zsh' \ - mafredri/zsh-async \ - romkatv/powerlevel10k \ +pick'async.zsh' \ + mafredri/zsh-async \ + romkatv/powerlevel10k \ zt for if'zct dolphin' \ - zdharma/null \ - if'zct p10k' \ - zdharma/null + z-shell/null \ +if'zct p10k' \ + z-shell/null zt light-mode compile'*handler' for \ - zinit-zsh/z-a-patch-dl \ - zinit-zsh/z-a-bin-gem-node \ - zinit-zsh/z-a-submods +z-shell/z-a-patch-dl \ +z-shell/z-a-bin-gem-node \ +z-shell/z-a-submods zt light-mode blockf for \ - _local/config-files +_local/config-files ########### # Plugins # ########### zt atinit'HISTFILE="${HOME}/.histfile"' for \ - OMZL::history.zsh + OMZL::history.zsh ###################### # Trigger-load block # ###################### zt light-mode for \ - trigger-load'!x' \ - OMZ::plugins/extract/extract.plugin.zsh \ - trigger-load'!man' \ - ael-code/zsh-colored-man-pages \ - trigger-load'!ga;!gcf;!gclean;!gd;!glo;!grh;!gss' \ - wfxr/forgit \ - trigger-load'!zshz' blockf \ - agkozak/zsh-z \ - trigger-load'!updatelocal' blockf \ - NICHOLAS85/updatelocal \ - trigger-load'!gencomp' pick'zsh-completion-generator.plugin.zsh' blockf \ - atload'alias gencomp="zinit silent nocd as\"null\" wait\"2\" atload\"zinit creinstall -q _local/config-files; zicompinit\" for /dev/null; gencomp"' \ - RobSis/zsh-completion-generator +trigger-load'!x' \ + OMZ::plugins/extract/extract.plugin.zsh \ +trigger-load'!man' \ + ael-code/zsh-colored-man-pages \ +trigger-load'!ga;!gcf;!gclean;!gd;!glo;!grh;!gss' \ + wfxr/forgit \ +trigger-load'!zshz' blockf \ + agkozak/zsh-z \ +trigger-load'!updatelocal' blockf \ + NICHOLAS85/updatelocal \ +trigger-load'!gencomp' pick'zsh-completion-generator.plugin.zsh' blockf \ +atload'alias gencomp="zi silent nocd as\"null\" wait\"2\" atload\"zi creinstall -q _local/config-files; zicompinit\" for /dev/null; gencomp"' \ + RobSis/zsh-completion-generator ################## # Wait'0a' block # ################## zt 0a light-mode for \ - OMZL::completion.zsh \ - if'false' ver'dev' \ - marlonrichert/zsh-autocomplete \ - has'systemctl' \ - OMZP::systemd/systemd.plugin.zsh \ - OMZP::sudo/sudo.plugin.zsh \ - blockf \ - zsh-users/zsh-completions \ - compile'{src/*.zsh,src/strategies/*}' pick'zsh-autosuggestions.zsh' \ - atload'_zsh_autosuggest_start' \ - zsh-users/zsh-autosuggestions \ - pick'fz.sh' atload'ZSH_AUTOSUGGEST_CLEAR_WIDGETS+=(autopair-insert __fz_zsh_completion)' \ - changyuheng/fz + OMZL::completion.zsh \ +if'false' ver'dev' \ + marlonrichert/zsh-autocomplete \ +has'systemctl' \ + OMZP::systemd/systemd.plugin.zsh \ + OMZP::sudo/sudo.plugin.zsh \ +blockf \ + zsh-users/zsh-completions \ +compile'{src/*.zsh,src/strategies/*}' pick'zsh-autosuggestions.zsh' \ +atload'_zsh_autosuggest_start' \ + zsh-users/zsh-autosuggestions \ +pick'fz.sh' atload'ZSH_AUTOSUGGEST_CLEAR_WIDGETS+=(autopair-insert __fz_zsh_completion)' \ + changyuheng/fz ################## # Wait'0b' block # ################## zt 0b light-mode for \ - pack'no-dir-color-swap' patch"$pchf/%PLUGIN%.patch" reset \ - trapd00r/LS_COLORS \ - compile'{hsmw-*,test/*}' \ - zdharma/history-search-multi-word \ - OMZP::command-not-found/command-not-found.plugin.zsh \ - pick'autopair.zsh' nocompletions atload'bindkey "^H" backward-kill-word; ZSH_AUTOSUGGEST_CLEAR_WIDGETS+=(autopair-insert)' \ - hlissner/zsh-autopair \ - trackbinds bindmap'\e[1\;6D -> ^[[1\;5B; \e[1\;6C -> ^[[1\;5A' patch"$pchf/%PLUGIN%.patch" \ - reset pick'dircycle.zsh' \ - michaelxmcbride/zsh-dircycle \ - autoload'#manydots-magic' \ - knu/zsh-manydots-magic \ - pick'autoenv.zsh' nocompletions \ - Tarrasch/zsh-autoenv \ - atinit'zicompinit_fast; zicdreplay' atload'FAST_HIGHLIGHT[chroma-man]=' \ - zdharma/fast-syntax-highlighting \ - atload'bindkey "$terminfo[kcuu1]" history-substring-search-up; - bindkey "$terminfo[kcud1]" history-substring-search-down' \ - zsh-users/zsh-history-substring-search \ - as'completion' mv'*.zsh -> _git' \ - felipec/git-completion \ +pack'no-dir-color-swap' patch"$pchf/%PLUGIN%.patch" reset \ + trapd00r/LS_COLORS \ +compile'{hsmw-*,test/*}' \ + z-shell/H-S-MW \ + OMZP::command-not-found/command-not-found.plugin.zsh \ +pick'autopair.zsh' nocompletions atload'bindkey "^H" backward-kill-word; ZSH_AUTOSUGGEST_CLEAR_WIDGETS+=(autopair-insert)' \ + hlissner/zsh-autopair \ +trackbinds bindmap'\e[1\;6D -> ^[[1\;5B; \e[1\;6C -> ^[[1\;5A' patch"$pchf/%PLUGIN%.patch" \ +reset pick'dircycle.zsh' \ + michaelxmcbride/zsh-dircycle \ +autoload'#manydots-magic' \ + knu/zsh-manydots-magic \ +pick'autoenv.zsh' nocompletions \ + Tarrasch/zsh-autoenv \ +atinit'zicompinit_fast; zicdreplay' atload'FAST_HIGHLIGHT[chroma-man]=' \ + z-shell/F-Sy-H \ +atload'bindkey "$terminfo[kcuu1]" history-substring-search-up; +bindkey "$terminfo[kcud1]" history-substring-search-down' \ + zsh-users/zsh-history-substring-search \ +as'completion' mv'*.zsh -> _git' \ + felipec/git-completion \ ################## # Wait'0c' block # ################## zt 0c light-mode for \ - pack'bgn-binary' \ - junegunn/fzf \ - sbin from'gh-r' submods'NICHOLAS85/zsh-fast-alias-tips -> plugin' pick'plugin/*.zsh' \ - sei40kr/fast-alias-tips-bin +pack'bgn-binary' \ + junegunn/fzf \ +sbin from'gh-r' submods'NICHOLAS85/zsh-fast-alias-tips -> plugin' pick'plugin/*.zsh' \ + sei40kr/fast-alias-tips-bin zt 0c light-mode binary for \ - sbin'fd*/fd;fd*/fd -> fdfind' from"gh-r" \ - @sharkdp/fd \ - sbin'bin/git-ignore' atload'export GI_TEMPLATE="$PWD/.git-ignore"; alias gi="git-ignore"' \ - laggardkernel/git-ignore +sbin'fd*/fd;fd*/fd -> fdfind' from"gh-r" \ + @sharkdp/fd \ +sbin'bin/git-ignore' atload'export GI_TEMPLATE="$PWD/.git-ignore"; alias gi="git-ignore"' \ + laggardkernel/git-ignore zt 0c light-mode null for \ - sbin"bin/git-dsf;bin/diff-so-fancy" \ - zdharma/zsh-diff-so-fancy \ - sbin \ - paulirish/git-open \ - sbin'm*/micro' from"gh-r" ver'nightly' bpick'*linux64*' reset \ - zyedidia/micro \ - sbin'*/rm-trash' atload'alias rm="rm-trash ${rm_opts}"' reset \ - patch"$pchf/%PLUGIN%.patch" \ - nateshmbhat/rm-trash \ - sbin \ - kazhala/dotbare \ - id-as'Cleanup' nocd atinit'unset -f zct zt; SPACESHIP_PROMPT_ADD_NEWLINE=true; _zsh_autosuggest_bind_widgets' \ - zdharma/null +sbin"bin/git-dsf;bin/diff-so-fancy" \ + z-shell/zsh-diff-so-fancy \ +sbin \ + paulirish/git-open \ +sbin'm*/micro' from"gh-r" ver'nightly' bpick'*linux64*' reset \ + zyedidia/micro \ +sbin'*/rm-trash' atload'alias rm="rm-trash ${rm_opts}"' reset \ +patch"$pchf/%PLUGIN%.patch" \ + nateshmbhat/rm-trash \ +sbin \ + kazhala/dotbare \ +id-as'Cleanup' nocd atinit'unset -f zct zt; SPACESHIP_PROMPT_ADD_NEWLINE=true; _zsh_autosuggest_bind_widgets' \ + z-shell/null diff --git a/agkozak/.profile b/agkozak/.profile index 3c418b4..36b340a 100644 --- a/agkozak/.profile +++ b/agkozak/.profile @@ -15,7 +15,7 @@ AGKDOT_SYSTEMINFO=$(uname -a) # Environment variables {{{1 export EDITOR VISUAL -if command -v vim > /dev/null 2>&1; then +if command -v vim >/dev/null 2>&1; then EDITOR='vim' else EDITOR='vi' @@ -26,15 +26,16 @@ export ENV ENV="$HOME/.shrc" case $(ls -l "$(command -v less)") in - *busybox*) ;; +*busybox*) ;; +*) + case $AGKDOT_SYSTEMINFO in + UWIN*) ;; *) - case $AGKDOT_SYSTEMINFO in - UWIN*) ;; - *) - export LESS - LESS='-R' - ;; - esac + export LESS + LESS='-R' + ;; + esac + ;; esac # if command -v lesspipe > /dev/null 2>&1; then @@ -68,22 +69,22 @@ PAGER=less export PATH # Construct $PATH -for i in "$HOME/.gem/ruby/2.4.0/bin" \ +for i in "$HOME/.gem/ruby/3.0.0/bin" \ "$HOME/.local/bin" \ "$HOME/go/bin" \ - "$HOME/.cabal/bin" \ - "$HOME/.config/composer/vendor/bin" \ - "$HOME/.composer/vendor/bin" \ + "$HOME/.cabal/bin" \ + "$HOME/.config/composer/vendor/bin" \ + "$HOME/.composer/vendor/bin" \ "$HOME/.luarocks/bin" \ - "$HOME/ruby/gems/bin" \ - "$HOME/.rvim/bin" \ - "$HOME/bin"; do + "$HOME/ruby/gems/bin" \ + "$HOME/.rvim/bin" \ + "$HOME/bin"; do if [ -d "$i" ]; then case :$PATH: in - *:$i:*) ;; - *) - PATH="$i:$PATH" - ;; + *:$i:*) ;; + *) + PATH="$i:$PATH" + ;; esac fi done @@ -91,7 +92,7 @@ done unset i case $AGKDOT_SYSTEMINFO in - *Msys) [ -d /mingw64/bin ] && PATH="$PATH:/mingw64/bin" ;; +*Msys) [ -d /mingw64/bin ] && PATH="$PATH:/mingw64/bin" ;; esac # Load RVM into a shell session *as a function* @@ -99,38 +100,38 @@ esac [ -s "$HOME/.rvm/scripts/rvm" ] && . "$HOME/.rvm/scripts/rvm" case $AGKDOT_SYSTEMINFO in - Darwin*|FreeBSD*) - export CLICOLOR LSCOLORS SSL_CERT_DIR SSL_CERT_FILE - CLICOLOR=1 - LSCOLORS='ExfxcxdxBxegedAbagacad' - SSL_CERT_DIR=/etc/ssl/certs - SSL_CERT_FILE=/etc/ssl/cert.pem - ;; - *Msys) - export MSYS SSL_CERT_DIR SSL_CERT_FILE - # `ln` creates native symlinks in Windows -- only works for administrator - MSYS="winsymlinks:nativestrict" - unset PYTHONHOME - [ ! -f /usr/bin/zsh ] && SHELL=/usr/bin/bash - SSL_CERT_DIR=/mingw64/ssl/certs - SSL_CERT_FILE=/mingw64/ssl/cert.pem - ;; - *Cygwin) - export CYGWIN - # `ln` creates native symlinks in Windows -- only works for administrator - CYGWIN="winsymlinks:native" - unset PYTHONHOME SSL_CERT_DIR SSL_CERT_FILE - ;; - *raspberrypi*) - command -v chromium-browser > /dev/null 2>&1 && BROWSER='chromium-browser' - ;; +Darwin* | FreeBSD*) + export CLICOLOR LSCOLORS SSL_CERT_DIR SSL_CERT_FILE + CLICOLOR=1 + LSCOLORS='ExfxcxdxBxegedAbagacad' + SSL_CERT_DIR=/etc/ssl/certs + SSL_CERT_FILE=/etc/ssl/cert.pem + ;; +*Msys) + export MSYS SSL_CERT_DIR SSL_CERT_FILE + # `ln` creates native symlinks in Windows -- only works for administrator + MSYS="winsymlinks:nativestrict" + unset PYTHONHOME + [ ! -f /usr/bin/zsh ] && SHELL=/usr/bin/bash + SSL_CERT_DIR=/mingw64/ssl/certs + SSL_CERT_FILE=/mingw64/ssl/cert.pem + ;; +*Cygwin) + export CYGWIN + # `ln` creates native symlinks in Windows -- only works for administrator + CYGWIN="winsymlinks:native" + unset PYTHONHOME SSL_CERT_DIR SSL_CERT_FILE + ;; +*raspberrypi*) + command -v chromium-browser >/dev/null 2>&1 && BROWSER='chromium-browser' + ;; esac # }}}1 # umask {{{1 -if [ "$(umask)" = "000" ]; then # For WSL +if [ "$(umask)" = "000" ]; then # For WSL umask 022 fi @@ -139,8 +140,8 @@ fi # Source ~/.profile.local {{{1 if [ -f "$HOME/.profile.local" ]; then - # shellcheck source=/dev/null - . "$HOME/.profile.local" + # shellcheck source=/dev/null + . "$HOME/.profile.local" fi # }}}1 diff --git a/agkozak/.zshrc b/agkozak/.zshrc index 306f0d0..d62d32b 100644 --- a/agkozak/.zshrc +++ b/agkozak/.zshrc @@ -1,8 +1,6 @@ # ~/.zshrc # # https://github.com/agkozak/dotfiles -# -# shellcheck disable=SC1090,SC2034,SC2128,SC2148,SC2154 # If zsh is emulating another shell {{{1 @@ -269,23 +267,23 @@ fi # }}}1 -# zinit {{{1 +# zi {{{1 if (( AGKDOT_NO_ZPLUGIN != 1 )) && is-at-least 5; then # Optional binary module - if [[ -f "$HOME/.zinit/bin/zmodules/Src/zdharma/zplugin.so" ]]; then - module_path+=( "$HOME/.zinit/bin/zmodules/Src" ) - zmodload zdharma/zplugin + if [[ -f "$HOME/.zi/zmodules/zpmod/Src/zi/zpmod.so" ]]; then + module_path+=( $HOME/.zi/zmodules/zpmod/Src ) + zmodload zi/zpmod fi if whence -w git &> /dev/null; then - if [[ ! -d ${HOME}/.zinit/bin ]]; then - print 'Installing zinit...' - mkdir -p "${HOME}/.zinit" - git clone https://github.com/zdharma/zinit.git "${HOME}/.zinit/bin" - compile_or_recompile "${HOME}/.zinit/bin/zinit.zsh" + if [[ ! -d ${HOME}/.zi/bin ]]; then + print 'Installing zi...' + mkdir -p "${HOME}/.zi" + git clone https://github.com/z-shell/zi.git "${HOME}/.zi/bin" + compile_or_recompile "${HOME}/.zi/bin/zi.zsh" fi # Configuration hash @@ -294,8 +292,8 @@ if (( AGKDOT_NO_ZPLUGIN != 1 )) && is-at-least 5; then # Location of .zcompdump file ZINIT[ZCOMPDUMP_PATH]="${HOME}/.zcompdump_${ZSH_VERSION}" - # zinit and its plugins and snippets - source "${HOME}/.zinit/bin/zinit.zsh" + # zi and its plugins and snippets + source "${HOME}/.zi/bin/zi.zsh" # Load plugins and snippets {{{2 @@ -305,12 +303,12 @@ if (( AGKDOT_NO_ZPLUGIN != 1 )) && is-at-least 5; then # AGKOZAK_MULTILINE=0 # AGKOZAK_PROMPT_CHAR=( '❯' '❯' '❮' ) # AGKOZAK_PROMPT_DEBUG=1 - zinit ver"develop" for agkozak/agkozak-zsh-prompt + zi ver"develop" for agkozak/agkozak-zsh-prompt - # zinit light agkozak/polyglot + # zi light agkozak/polyglot # if which kubectl &> /dev/null; then - # zinit light jonmosco/kube-ps1 - # zinit light agkozak/polyglot-kube-ps1 + # zi light jonmosco/kube-ps1 + # zi light agkozak/polyglot-kube-ps1 # fi # agkozak/zsh-z @@ -318,23 +316,23 @@ if (( AGKDOT_NO_ZPLUGIN != 1 )) && is-at-least 5; then ZSHZ_DEBUG=1 [[ $OSTYPE == freebsd* ]] && typeset -g ZSHZ_NO_RESOLVE_SYMLINKS=1 - zinit ver"develop" lucid wait for \ + zi ver"develop" lucid wait for \ agkozak/zhooks \ agkozak/zsh-z # zsh-titles causes dittography in Emacs shell and Vim terminal if (( ! $+EMACS )) && [[ $TERM != 'dumb' ]] && (( ! $+VIM_TERMINAL )); then - zinit lucid wait for jreese/zsh-titles + zi lucid wait for jreese/zsh-titles fi if [[ $AGKDOT_SYSTEMINFO != *ish* ]]; then - zinit lucid wait for zdharma/zui - zinit lucid wait'1' for zdharma/zbrowse + zi lucid wait for z-shell/zui + zi lucid wait'1' for z-shell/zbrowse fi - zinit snippet OMZ::plugins/extract/extract.plugin.zsh + zi snippet OMZ::plugins/extract/extract.plugin.zsh - zinit lucid wait for zsh-users/zsh-history-substring-search + zi lucid wait for zsh-users/zsh-history-substring-search HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_FOUND='underline' HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_NOT_FOUND='' zle -N history-substring-search-up @@ -348,13 +346,13 @@ if (( AGKDOT_NO_ZPLUGIN != 1 )) && is-at-least 5; then if [[ $OSTYPE == (msys|cygwin) ]] \ || [[ $AGKDOT_SYSTEMINFO == *Microsoft* ]]; then # Git highlighting can be very slow on Windows - zinit ice \ + zi ice \ atload'unset "FAST_HIGHLIGHT[chroma-git]"; fast-theme free &> /dev/null' \ lucid wait else - zinit ice atload'fast-theme free &> /dev/null' lucid wait + zi ice atload'fast-theme free &> /dev/null' lucid wait fi - zinit load zdharma/fast-syntax-highlighting + zi load z-shell/F-Sy-H else print 'Please install git.' @@ -380,7 +378,7 @@ fi autoload -Uz compinit compinit -u -d "${HOME}/.zcompdump_${ZSH_VERSION}" -(( ! AGKDOT_NO_ZPLUGIN )) && is-at-least 5 && zinit cdreplay -q +(( ! AGKDOT_NO_ZPLUGIN )) && is-at-least 5 && zi cdreplay -q # https://www.zsh.org/mla/users/2015/msg00467.html # shellcheck disable=SC2016 @@ -488,10 +486,10 @@ KEYTIMEOUT=1 # Static named directories [[ -d ${HOME}/public_html/wp-content ]] \ && hash -d wp-content="$HOME/public_html/wp-content" -[[ -d ${HOME}/.zinit/plugins/agkozak---agkozak-zsh-prompt ]] \ - && hash -d agk="$HOME/.zinit/plugins/agkozak---agkozak-zsh-prompt" -[[ -d ${HOME}/.zinit/plugins/agkozak---zsh-z ]] \ - && hash -d z="$HOME/.zinit/plugins/agkozak---zsh-z" +[[ -d ${HOME}/.zi/plugins/agkozak---agkozak-zsh-prompt ]] \ + && hash -d agk="$HOME/.zi/plugins/agkozak---agkozak-zsh-prompt" +[[ -d ${HOME}/.zi/plugins/agkozak---zsh-z ]] \ + && hash -d z="$HOME/.zi/plugins/agkozak---zsh-z" # Dynamic named directories # https://superuser.com/questions/751523/dynamic-directory-hash diff --git a/brucebentley/zshrc.zsh b/brucebentley/zshrc.zsh index 9f66c9e..d1fff91 100644 --- a/brucebentley/zshrc.zsh +++ b/brucebentley/zshrc.zsh @@ -6,11 +6,11 @@ PROFILE_STARTUP=false if [[ "$PROFILE_STARTUP" == true ]]; then - zmodload zsh/zprof - # http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html - PS4=$'%D{%M%S%.} %N:%i> ' - exec 3>&2 2>$HOME/startlog.$$ - setopt xtrace prompt_subst + zmodload zsh/zprof + # http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html + PS4=$'%D{%M%S%.} %N:%i> ' + exec 3>&2 2>$HOME/startlog.$$ + setopt xtrace prompt_subst fi @@ -22,7 +22,7 @@ fi # Initialization code that may require console input ( password prompts, [y/n] # confirmations, etc. ) must go above this block, everything else may go below. if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then - source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" + source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" fi @@ -154,22 +154,22 @@ setopt extended_history # Show Timestamp In History. # - - - - - - - - - - - - - - - - - - - - -# Zinit Configuration +# ZI Configuration # - - - - - - - - - - - - - - - - - - - - -__ZINIT="${ZDOTDIR:-$HOME}/.zinit/bin/zinit.zsh" +__ZI="${ZDOTDIR:-$HOME}/.zi/bin/zi.zsh" -if [[ ! -f "$__ZINIT" ]]; then - print -P "%F{33}▓▒░ %F{220}Installing DHARMA Initiative Plugin Manager (zdharma/zinit)…%f" - command mkdir -p "$HOME/.zinit" && command chmod g-rwX "$HOME/.zinit" - command git clone https://github.com/zdharma/zinit "$HOME/.zinit/bin" && \ - print -P "%F{33}▓▒░ %F{34}Installation successful.%f%b" || \ - print -P "%F{160}▓▒░ The clone has failed.%f%b" +if [[ ! -f "$__ZI" ]]; then + print -P "%F{33}▓▒░ %F{220}Installing ZI Initiative Plugin Manager (z-shell/zi)…%f" + command mkdir -p "$HOME/.zi" && command chmod g-rwX "$HOME/.zi" + command git clone https://github.com/z-shell/zi "$HOME/.zi/bin" && \ + print -P "%F{33}▓▒░ %F{34}Installation successful.%f%b" || \ + print -P "%F{160}▓▒░ The clone has failed.%f%b" fi -. "$__ZINIT" -autoload -Uz _zinit -(( ${+_comps} )) && _comps[zinit]=_zinit +. "$__ZI" +autoload -Uz _zi +(( ${+_comps} )) && _comps[zi]=_zi # - - - - - - - - - - - - - - - - - - - - @@ -180,77 +180,77 @@ autoload -Uz _zinit setopt promptsubst # These plugins provide many aliases - atload'' -zinit wait lucid for \ - OMZ::lib/git.zsh \ - atload"unalias grv" \ - OMZ::plugins/git/git.plugin.zsh +zi wait lucid for \ + OMZ::lib/git.zsh \ +atload"unalias grv" \ + OMZ::plugins/git/git.plugin.zsh # Provide A Simple Prompt Till The Theme Loads PS1="READY >" -zinit ice wait'!' lucid -zinit ice depth=1; zinit light romkatv/powerlevel10k +zi ice wait'!' lucid +zi ice depth=1; zi light romkatv/powerlevel10k # - - - - - - - - - - - - - - - - - - - - # Annexes # - - - - - - - - - - - - - - - - - - - - -# Load a few important annexes, without Turbo (this is currently required for annexes) -zinit light-mode compile"handler" for \ - zinit-zsh/z-a-patch-dl \ - zinit-zsh/z-a-as-monitor \ - zinit-zsh/z-a-bin-gem-node \ - zinit-zsh/z-a-submods \ - zdharma/declare-zsh +# Load a few important annexes, without Turbo. +zi light-mode compile"handler" for \ +z-shell/z-a-patch-dl \ +z-shell/z-a-readurl \ +z-shell/z-a-bin-gem-node \ +z-shell/z-a-submods \ +z-shell/declare-zsh # - - - - - - - - - - - - - - - - - - - - # Plugins # - - - - - - - - - - - - - - - - - - - - -zinit wait lucid light-mode for \ - OMZ::lib/compfix.zsh \ - OMZ::lib/completion.zsh \ - OMZ::lib/functions.zsh \ - OMZ::lib/diagnostics.zsh \ - OMZ::lib/git.zsh \ - OMZ::lib/grep.zsh \ - OMZ::lib/key-bindings.zsh \ - OMZ::lib/misc.zsh \ - OMZ::lib/spectrum.zsh \ - OMZ::lib/termsupport.zsh \ - OMZ::plugins/git-auto-fetch/git-auto-fetch.plugin.zsh \ - atinit"zicompinit; zicdreplay" \ - zdharma/fast-syntax-highlighting \ - OMZ::plugins/colored-man-pages/colored-man-pages.plugin.zsh \ - OMZ::plugins/command-not-found/command-not-found.plugin.zsh \ - atload"_zsh_autosuggest_start" \ - zsh-users/zsh-autosuggestions \ - as"completion" \ - OMZ::plugins/docker/_docker \ - OMZ::plugins/composer/composer.plugin.zsh \ - OMZ::plugins/thefuck/thefuck.plugin.zsh \ - htlsne/zplugin-rbenv \ - OMZ::plugins/pyenv/pyenv.plugin.zsh +zi wait lucid light-mode for \ + OMZ::lib/compfix.zsh \ + OMZ::lib/completion.zsh \ + OMZ::lib/functions.zsh \ + OMZ::lib/diagnostics.zsh \ + OMZ::lib/git.zsh \ + OMZ::lib/grep.zsh \ + OMZ::lib/key-bindings.zsh \ + OMZ::lib/misc.zsh \ + OMZ::lib/spectrum.zsh \ + OMZ::lib/termsupport.zsh \ + OMZ::plugins/git-auto-fetch/git-auto-fetch.plugin.zsh \ +atinit"zicompinit; zicdreplay" \ + z-shell/F-Sy-H \ + OMZ::plugins/colored-man-pages/colored-man-pages.plugin.zsh \ + OMZ::plugins/command-not-found/command-not-found.plugin.zsh \ +atload"_zsh_autosuggest_start" \ + zsh-users/zsh-autosuggestions \ +as"completion" \ + OMZ::plugins/docker/_docker \ + OMZ::plugins/composer/composer.plugin.zsh \ + OMZ::plugins/thefuck/thefuck.plugin.zsh \ + htlsne/zplugin-rbenv \ + OMZ::plugins/pyenv/pyenv.plugin.zsh # Recommended Be Loaded Last. -zinit ice wait blockf lucid atpull'zinit creinstall -q .' -zinit load zsh-users/zsh-completions +zi ice wait blockf lucid atpull'zi creinstall -q .' +zi load zsh-users/zsh-completions # rbenv -# zinit ice has'rbenv' id-as'rbenv' atpull'%atclone' \ +# zi ice has'rbenv' id-as'rbenv' atpull'%atclone' \ # atclone"rbenv init - --no-rehash > htlsne/zplugin-rbenv" -# zinit load zdharma/null +# zi load z-shell/null # pyenv -# zinit ice has'pyenv' id-as'pyenv' atpull'%atclone' \ +# zi ice has'pyenv' id-as'pyenv' atpull'%atclone' \ # atclone"pyenv init - --no-rehash > pyenv.plugin.zsh" -# zinit load zdharma/null +# zi load z-shell/null -# Semi-graphical .zshrc editor for zinit commands -zinit load zdharma/zui -zinit ice lucid wait'[[ -n ${ZLAST_COMMANDS[(r)cras*]} ]]' -zinit load zdharma/zplugin-crasis +# Semi-graphical .zshrc editor for zi commands +zi load z-shell/zui +zi ice lucid wait'[[ -n ${ZLAST_COMMANDS[(r)cras*]} ]]' +zi load z-shell/zplugin-crasis # - - - - - - - - - - - - - - - - - - - - @@ -267,12 +267,12 @@ setopt no_beep # [[ -f ~/.zshrc.local ]] && source ~/.zshrc.local foreach piece ( - exports.zsh - node.zsh - aliases.zsh - functions.zsh + exports.zsh + node.zsh + aliases.zsh + functions.zsh ) { - . $ZSH/config/$piece + . $ZSH/config/$piece } @@ -286,18 +286,18 @@ DIRSTACKFILE="$HOME/.cache/zsh/dirs" # Make `DIRSTACKFILE` If It 'S Not There. if [[ ! -a $DIRSTACKFILE ]]; then - mkdir -p $DIRSTACKFILE[0,-5] - touch $DIRSTACKFILE + mkdir -p $DIRSTACKFILE[0,-5] + touch $DIRSTACKFILE fi if [[ -f $DIRSTACKFILE ]] && [[ $#dirstack -eq 0 ]]; then - dirstack=( ${(f)"$(< $DIRSTACKFILE)"} ) + dirstack=( ${(f)"$(< $DIRSTACKFILE)"} ) fi chpwd() { - print -l $PWD ${(u)dirstack} >>$DIRSTACKFILE - local d="$(sort -u $DIRSTACKFILE )" - echo "$d" > $DIRSTACKFILE + print -l $PWD ${(u)dirstack} >>$DIRSTACKFILE + local d="$(sort -u $DIRSTACKFILE )" + echo "$d" > $DIRSTACKFILE } DIRSTACKSIZE=20 @@ -321,7 +321,7 @@ setopt pushd_minus # This Reverts The +/- Operators. # - - - - - - - - - - - - - - - - - - - - if [[ "$PROFILE_STARTUP" == true ]]; then - unsetopt xtrace - exec 2>&3 3>&- - zprof > ~/zshprofile$(date +'%s') + unsetopt xtrace + exec 2>&3 3>&- + zprof > ~/zshprofile$(date +'%s') fi diff --git a/jubi/.zshrc b/jubi/.zshrc index aaf1918..5540a63 100644 --- a/jubi/.zshrc +++ b/jubi/.zshrc @@ -1,27 +1,27 @@ ### Added by Zinit's installer -source ~/.zinit/bin/zinit.zsh -autoload -Uz _zinit -(( ${+_comps} )) && _comps[zinit]=_zinit +source ~/.zi/bin/zi.zsh +autoload -Uz _zi +(( ${+_comps} )) && _comps[zi]=_zi ### End of Zinit installer's chunk ##### BEGIN Zinit stuff ##### -### needs: zinit, fzf +### needs: zi, fzf # z -zinit ice wait blockf lucid -zinit light rupa/z +zi ice wait blockf lucid +zi light rupa/z # z tab completion -zinit ice wait lucid -zinit light changyuheng/fz +zi ice wait lucid +zi light changyuheng/fz # z / fzf (ctrl-g) -zinit ice wait lucid -zinit light andrewferrier/fzf-z +zi ice wait lucid +zi light andrewferrier/fzf-z # cd -zinit ice wait lucid -zinit light changyuheng/zsh-interactive-cd +zi ice wait lucid +zi light changyuheng/zsh-interactive-cd # Don't bind these keys until ready bindkey -r '^[[A' @@ -31,20 +31,20 @@ function __bind_history_keys() { bindkey '^[[B' history-substring-search-down } # History substring searching -zinit ice wait lucid atload'__bind_history_keys' -zinit light zsh-users/zsh-history-substring-search +zi ice wait lucid atload'__bind_history_keys' +zi light zsh-users/zsh-history-substring-search # autosuggestions, trigger precmd hook upon load -zinit ice wait lucid atload'_zsh_autosuggest_start' -zinit light zsh-users/zsh-autosuggestions +zi ice wait lucid atload'_zsh_autosuggest_start' +zi light zsh-users/zsh-autosuggestions export ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=10 # Tab completions -zinit ice wait lucid blockf atpull'zinit creinstall -q .' -zinit light zsh-users/zsh-completions +zi ice wait lucid blockf atpull'zi creinstall -q .' +zi light zsh-users/zsh-completions # Syntax highlighting -zinit ice wait lucid atinit'zpcompinit; zpcdreplay' -zinit light zdharma/fast-syntax-highlighting +zi ice wait lucid atinit'zicompinit; zicdreplay' +zi light z-shell/F-Sy-H ##### END Zinit stuff ##### diff --git a/lainiwa/1st_config/.zsh/aliases.zsh b/lainiwa/1st_config/.zsh/aliases.zsh index 5532fcf..6310027 100755 --- a/lainiwa/1st_config/.zsh/aliases.zsh +++ b/lainiwa/1st_config/.zsh/aliases.zsh @@ -1,9 +1,8 @@ - # Colorize and humanify `ls` if [[ "$(uname -s)" == "FreeBSD" ]]; then - alias ls='ls -h -G' + alias ls='ls -h -G' else - alias ls='ls -h --color=auto' + alias ls='ls -h --color=auto' fi alias ll='ls -l' alias la='ls -A' @@ -18,14 +17,14 @@ alias mkdir='mkdir -pv' alias tree='tree -C' alias U='unbuffer ' -alias -g H="| sed 11q" # (: +alias -g H="| sed 11q" # (: alias -g T="| tail" alias -g G="| grep" alias -g S="| sed" alias -g L="| less" -alias -g LR="| less -R" # less with colors support +alias -g LR="| less -R" # less with colors support alias -g C='| column -t' @@ -33,30 +32,26 @@ alias -g NE="2> /dev/null" alias -g NUL="&> /dev/null" # Set grc alias for available commands. -[[ -f /etc/grc.conf ]] && grc_conf='/etc/grc.conf' +[[ -f /etc/grc.conf ]] && grc_conf='/etc/grc.conf' [[ -f /usr/local/etc/grc.conf ]] && grc_conf='/usr/local/etc/grc.conf' if [ ! -z "$grc_conf" ]; then - for cmd in $(grep '^# ' "$grc_conf" | cut -f 2 -d ' '); do - if (( $+commands[$cmd] )) && [ "$cmd" != "ls" ]; then - alias $cmd="grc --colour=auto $cmd" - fi - done + for cmd in $(grep '^# ' "$grc_conf" | cut -f 2 -d ' '); do + if (($ + commands[$cmd])) && [ "$cmd" != "ls" ]; then + alias $cmd="grc --colour=auto $cmd" + fi + done fi - # Create directory and cd to it -mkcd() { mkdir -- "$1" && cd -P -- "$1" ; } - +mkcd() { mkdir -- "$1" && cd -P -- "$1"; } # Alias for altering some symbol with newline # Example: echo $PATH TRN : -__rt__() { tr -- "$2" "$1" ; } +__rt__() { tr -- "$2" "$1"; } alias -g TRN='| __rt__ "\n" ' - # Remove colors alias -g NOC='| sed -r "s/\x1B\[[0-9;]*[JKmsu]//g"' - # npm-exec binary_name, to run localy installed nodejs binary alias npm-exec='PATH=$(npm bin):$PATH' diff --git a/lainiwa/1st_config/.zsh/completions/_my b/lainiwa/1st_config/.zsh/completions/_my index 99846a6..1b06277 100644 --- a/lainiwa/1st_config/.zsh/completions/_my +++ b/lainiwa/1st_config/.zsh/completions/_my @@ -1,6 +1,5 @@ #compdef _my my - _my() { local line @@ -42,33 +41,31 @@ _my() { "*::arg:->args" case $line[1] in - set_bg) - _set_bg + set_bg) + _set_bg ;; - save_4chan_thread_imgs) - _save_4chan_thread_imgs + save_4chan_thread_imgs) + _save_4chan_thread_imgs ;; - screenshot) - _screenshot + screenshot) + _screenshot ;; - graph_dependencies) - _graph_dependencies + graph_dependencies) + _graph_dependencies ;; - pastebin) - _pastebin + pastebin) + _pastebin ;; - install_package) - _install_package + install_package) + _install_package ;; - dependencies) - _dependencies + dependencies) + _dependencies ;; esac - } - _set_bg() { local line @@ -77,26 +74,25 @@ _set_bg() { "*::arg:->args" case $line[1] in - *) - _files -g "*.(jpg|jpeg|png)" + *) + _files -g "*.(jpg|jpeg|png)" ;; esac } - _save_4chan_thread_imgs() { local -a commands IFS=$'\n' commands=($( curl --silent 'http://www.4chan.org/' | - grep '^