diff options
Diffstat (limited to 'zsh')
l--------- | zsh/.zshrc | 1 | ||||
-rwxr-xr-x | zsh/profiles/zprofile.libreX60 | 4 | ||||
-rwxr-xr-x | zsh/profiles/zprofile.voidx250 | 3 | ||||
-rw-r--r-- | zsh/zplugs | 1 | ||||
-rwxr-xr-x | zsh/zprofile | 55 | ||||
-rwxr-xr-x | zsh/zscripts/!rootcolors.zsh | 3 | ||||
-rwxr-xr-x | zsh/zscripts/.lfub.zsh | 27 | ||||
-rwxr-xr-x | zsh/zscripts/aliasrc.zsh | 64 | ||||
-rwxr-xr-x | zsh/zscripts/hosts/aliasrc.G3N2.zsh | 6 | ||||
l--------- | zsh/zscripts/hosts/aliasrc.T495.zsh | 1 | ||||
-rwxr-xr-x | zsh/zscripts/hosts/aliasrc.desktop.zsh | 12 | ||||
-rwxr-xr-x | zsh/zscripts/hosts/aliasrc.libreX60.zsh | 11 | ||||
-rwxr-xr-x | zsh/zscripts/hosts/aliasrc.voidx250.zsh | 8 | ||||
-rwxr-xr-x | zsh/zscripts/hosts/colors.desktop.zsh | 9 | ||||
-rwxr-xr-x | zsh/zscripts/hosts/colors.voidx250.zsh | 9 | ||||
-rwxr-xr-x | zsh/zscripts/keybindrc.zsh | 24 | ||||
-rwxr-xr-x | zsh/zscripts/nicegit.zsh | 31 | ||||
-rwxr-xr-x | zsh/zscripts/shortcuts.zsh | 12 | ||||
-rwxr-xr-x | zsh/zscripts/terminalname.zsh | 8 | ||||
-rwxr-xr-x | zsh/zscripts/termuxprompt.zsh | 8 | ||||
-rwxr-xr-x | zsh/zscripts/vicursor.zsh | 21 | ||||
-rwxr-xr-x | zsh/zscripts/zplug.zsh | 136 | ||||
-rwxr-xr-x | zsh/zscripts/zshcompmenu.zsh | 18 | ||||
-rwxr-xr-x | zsh/zshrc | 32 |
24 files changed, 0 insertions, 504 deletions
diff --git a/zsh/.zshrc b/zsh/.zshrc deleted file mode 120000 index c8b42f4..0000000 --- a/zsh/.zshrc +++ /dev/null @@ -1 +0,0 @@ -zshrc
\ No newline at end of file diff --git a/zsh/profiles/zprofile.libreX60 b/zsh/profiles/zprofile.libreX60 deleted file mode 100755 index d4f4e9c..0000000 --- a/zsh/profiles/zprofile.libreX60 +++ /dev/null @@ -1,4 +0,0 @@ -#!/usr/bin/env zsh - -export WM="awesome" -export TERMINAL="st" diff --git a/zsh/profiles/zprofile.voidx250 b/zsh/profiles/zprofile.voidx250 deleted file mode 100755 index 61eb34e..0000000 --- a/zsh/profiles/zprofile.voidx250 +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env zsh - -export XDG_DATA_DIRS="/var/lib/flatpak/exports/share:$XDG_DATA_DIRS" # .desktop files diff --git a/zsh/zplugs b/zsh/zplugs deleted file mode 100644 index 845f5c6..0000000 --- a/zsh/zplugs +++ /dev/null @@ -1 +0,0 @@ -https://github.com/zdharma-continuum/fast-syntax-highlighting diff --git a/zsh/zprofile b/zsh/zprofile deleted file mode 100755 index f7b2549..0000000 --- a/zsh/zprofile +++ /dev/null @@ -1,55 +0,0 @@ -#!/usr/bin/env zsh - -# Default programs -export EDITOR='nvim' -export TERMINAL='alacritty' -export BROWSER='launch firefox' -export SUDO='doas' - -# Use sudo=${SUDO-sudo} -[ $EUID = 0 ] && export SUDO='' # When running as root, don't use sudo - -# Make programs follow the XDG base directory specification -export XDG_CACHE_HOME="$HOME/.cache" -export ANSIBLE_GALAXY_CACHE_DIR="${XDG_CACHE_HOME}/ansible/galaxy_cache" -export DOCKER_CONFIG="$XDG_CACHE_HOME/docker" -export XAUTHORITY="$XDG_CACHE_HOME/Xauthority" - -export XDG_CONFIG_HOME="$HOME/.config" -export ANSIBLE_HOME="${XDG_CONFIG_HOME}/ansible" -export ANSIBLE_CONFIG="${XDG_CONFIG_HOME}/ansible/ansible.cfg" -export GTK2_RC_FILES="$XDG_CONFIG_HOME/gtk-2.0/gtkrc" -export MBSYNCRC="$XDG_CONFIG_HOME/mbsync/config" -export NOTMUCH_CONFIG="$XDG_CONFIG_HOME/notmuch/config" -export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc" -export X11CONFIG="$XDG_CONFIG_HOME/x11" # Used for X11 scripts -export ZDOTDIR="$XDG_CONFIG_HOME/zsh" - -export XDG_DATA_HOME="$HOME/.local/share" -export CARGO_HOME="$XDG_DATA_HOME/cargo" -export GNUPGHOME="$XDG_DATA_HOME/gnupg" -export GRADLE_USER_HOME="$XDG_DATA_HOME/gradle" -export PASSWORD_STORE_DIR="$XDG_DATA_HOME/password-store" -export PYTHONUSERBASE="$XDG_DATA_HOME/python" -export _JAVA_OPTIONS="-Djava.util.prefs.userRoot=$XDG_DATA_HOME/java" - -export XDG_STATE_HOME="$HOME/.local/state" -export LESSHISTFILE='-' # Disable this, but it would be considered a state file -export ZHISTFILE="$XDG_STATE_HOME/zsh/zhistory" # Used to set HISTFILE in zshrc without exporting since HISTFILE is generic to most shells, and desired behavior is for zsh to have its own history file - -# Path -setopt nullglob # Set in case .local/bin doesn't exist -for lbin in "$HOME/.local/bin"{/,/*/}; do export PATH="${lbin%/}:$PATH"; done 2>/dev/null # Add ~/.local/bin and all sub dirs -export PATH="$HOME/.local/opt:$PATH" -export PATH="$CARGO_HOME/bin:$PATH" -export PATH="$PYTHONUSERBASE/bin:$PATH" - -# Theming -export QT_QPA_PLATFORMTHEME='gtk2' - -# Misc Zsh setup -mkdir -p "$(dirname "$ZHISTFILE")" -source "$ZDOTDIR/profiles/zprofile.$HOST" 2>/dev/null # Source additional host-specific profiles - -# Autostart X after login -[ -z $DISPLAY ] && [[ $UID != 0 ]] && [[ $TTY =~ /dev/tty(1|C0) ]] && startx "$X11CONFIG/xinitrc" diff --git a/zsh/zscripts/!rootcolors.zsh b/zsh/zscripts/!rootcolors.zsh deleted file mode 100755 index d146aa5..0000000 --- a/zsh/zscripts/!rootcolors.zsh +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env zsh - -[ $EUID = 0 ] && declare col{br,name,at,host,dir}=red && clear # Clear to get rid of last login message diff --git a/zsh/zscripts/.lfub.zsh b/zsh/zscripts/.lfub.zsh deleted file mode 100755 index 2e1f7f4..0000000 --- a/zsh/zscripts/.lfub.zsh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh -# This is a wrapper script for lf that allows it to create image previews with -# ueberzug. This works in concert with the lf configuration file and the -# lf-cleaner script. - -cleanuplf() { - exec 3>&- - \rm "$FIFO_UEBERZUG" -} - -lfub() { - dircache=/tmp/$USER-lflastdir - lfopt="--last-dir-path=$dircache" - if [ -n "$SSH_CLIENT" ] || [ -n "$SSH_TTY" ]; then - lf "$lfopt" "$@" - else - export FIFO_UEBERZUG="/tmp/ueberzug-$$" - mkfifo "$FIFO_UEBERZUG" - ueberzug layer -s <"$FIFO_UEBERZUG" -p json & - exec 3>"$FIFO_UEBERZUG" - trap cleanuplf HUP INT QUIT TERM PWR EXIT - lf "$lfopt" "$@" 3>&- - fi - [ -f "$dircache" ] && dir="$(cat "$dircache")" && [ -d "$dir" ] && cd "$dir" -} - -alias lf="lfub" diff --git a/zsh/zscripts/aliasrc.zsh b/zsh/zscripts/aliasrc.zsh deleted file mode 100755 index f4e5035..0000000 --- a/zsh/zscripts/aliasrc.zsh +++ /dev/null @@ -1,64 +0,0 @@ -#!/usr/bin/env zsh - -# Replacement programs -typeset -A repaliases=( - #alias replacement - htop htim - mutt neomutt - vim nvim - sudo "${SUDO:- }" - neofetch fastfetch -) -for alias rep in ${(kv)repaliases}; do - command -v $rep >/dev/null && alias $alias=$rep -done # Tests if replacement exists before creating alias - - -# Shorten program names -alias \ - open="xdg-open" \ - smci="sudo make clean install" \ - smi="sudo make install" \ - su="sudo su -l" \ - -# Power scripts -alias \ - halt="launch shutdown" \ - off="launch shutdown" \ - reboot="launch reboot" \ - zzz="launch suspend" \ - -# Colorize command output -alias \ - bat="bat --theme='Monokai Extended'" \ - diff="diff --color=auto" \ - exa="exa --icons -a --group-directories-first" \ - grep="grep --color=auto -I --ignore-case --line-number" \ - ip="ip --color=auto" \ - ls="ls -vAhN --color=auto --group-directories-first" \ - -# (Non)-Verbosity -alias \ - cp="cp -iv" \ - dd="sudo dd status=progress bs=4M" - ffmpeg="ffmpeg -hide_banner" \ - ffprobe="ffprobe -hide_banner" \ - mkd="mkdir -p" \ - mv="mv -iv" \ - rm="rm -v" \ - -# Miscellaneous -alias \ - yt-dlp-album="yt-dlp -x -o '%(uploader)s (%(upload_date>%Y)s) - %(playlist_title)s%%%(playlist_index)s - %(title)s.%(ext)s'" \ - yt-dlp="yt-dlp -o '%(uploader)s - %(title)s.%(ext)s'" \ - -# Clean home directory -alias \ - mbsync="mbsync --config $MBSYNCRC" \ - startx="startx $X11CONFIG/xinitrc" \ - -# Copy-pasting from internet -alias \ - \$="" \ - \#="${SUDO-sudo}" \ - diff --git a/zsh/zscripts/hosts/aliasrc.G3N2.zsh b/zsh/zscripts/hosts/aliasrc.G3N2.zsh deleted file mode 100755 index 8e8d2a5..0000000 --- a/zsh/zscripts/hosts/aliasrc.G3N2.zsh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -# Package Management -alias \ - e="sudo emerge" \ - diff --git a/zsh/zscripts/hosts/aliasrc.T495.zsh b/zsh/zscripts/hosts/aliasrc.T495.zsh deleted file mode 120000 index 6c84487..0000000 --- a/zsh/zscripts/hosts/aliasrc.T495.zsh +++ /dev/null @@ -1 +0,0 @@ -aliasrc.desktop.zsh
\ No newline at end of file diff --git a/zsh/zscripts/hosts/aliasrc.desktop.zsh b/zsh/zscripts/hosts/aliasrc.desktop.zsh deleted file mode 100755 index 141212f..0000000 --- a/zsh/zscripts/hosts/aliasrc.desktop.zsh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/sh - -# Package Management -alias \ - d="sudo dnf" \ - dnf="sudo dnf" \ - -# Shorten program names -alias \ - systemctl="sudo systemctl" \ - sd="systemctl" \ - diff --git a/zsh/zscripts/hosts/aliasrc.libreX60.zsh b/zsh/zscripts/hosts/aliasrc.libreX60.zsh deleted file mode 100755 index 1180171..0000000 --- a/zsh/zscripts/hosts/aliasrc.libreX60.zsh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/sh - -# Package Management -alias \ - apt="sudo apt" \ - -# Shorten program names -alias \ - systemctl="sudo systemctl" \ - sd="systemctl" \ - diff --git a/zsh/zscripts/hosts/aliasrc.voidx250.zsh b/zsh/zscripts/hosts/aliasrc.voidx250.zsh deleted file mode 100755 index 4bb85ea..0000000 --- a/zsh/zscripts/hosts/aliasrc.voidx250.zsh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh - -# Package Management -alias \ - xi="sudo xbps-install" \ - xq="xbps-query -R --search" \ - xr="sudo xbps-remove" \ - diff --git a/zsh/zscripts/hosts/colors.desktop.zsh b/zsh/zscripts/hosts/colors.desktop.zsh deleted file mode 100755 index dee7ed3..0000000 --- a/zsh/zscripts/hosts/colors.desktop.zsh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env zsh - -if [ -n "$DISPLAY" ]; then - declare col{br,at}=57 - declare col{name,host}=13 - coldir=129 -else - declare col{br,name,at,host,dir}=magenta -fi diff --git a/zsh/zscripts/hosts/colors.voidx250.zsh b/zsh/zscripts/hosts/colors.voidx250.zsh deleted file mode 100755 index 910f1f9..0000000 --- a/zsh/zscripts/hosts/colors.voidx250.zsh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env zsh - -if [ -n "$DISPLAY" ]; then - declare col{br,at}=green - declare col{name,host}=76 - coldir=40 -else - declare col{br,name,at,host,dir}=green -fi diff --git a/zsh/zscripts/keybindrc.zsh b/zsh/zscripts/keybindrc.zsh deleted file mode 100755 index 2f2e664..0000000 --- a/zsh/zscripts/keybindrc.zsh +++ /dev/null @@ -1,24 +0,0 @@ -#!/usr/bin/env zsh - -# Vi mode + requirements for ALL keybindings to work correctly -bindkey -v # Select viins keymap -KEYTIMEOUT=1 - -# Keybindings -autoload edit-command-line; zle -N edit-command-line # Edit line in Vim buffer -bindkey '^E' edit-command-line # Ctrl-e - edit line in Vim buffer - -bindkey '^[[P' delete-char # Delete Key -bindkey '^[[F' end-of-line # End Key -bindkey '^[[H' beginning-of-line # Home Key -bindkey '^[[2~' overwrite-mode # Insert Key -bindkey '^D' kill-whole-line # Ctrl-d - delete line -bindkey '^X' clear-screen # Ctrl-x - clear screen -bindkey '^H' backward-delete-word # Ctrl-Backspace - delete entire word behind cursor -bindkey '^[[3;5~' delete-word # Ctrl-Delete - delete currect word in front of the cursor -# History completion -bindkey '\e[A' history-search-backward # Up arrow - seach history backwards -bindkey '\e[B' history-search-forward # Down arrow - seach history forwards - -# Ignore ctrl-d to exit shell -setopt IGNORE_EOF diff --git a/zsh/zscripts/nicegit.zsh b/zsh/zscripts/nicegit.zsh deleted file mode 100755 index 276d98e..0000000 --- a/zsh/zscripts/nicegit.zsh +++ /dev/null @@ -1,31 +0,0 @@ -#!/usr/bin/env zsh - -alias \ - ga="git add" \ - gpl="git pull" \ - gph="git push" \ - gl="git log" \ - gldaily='git log --pretty="format:- %s" --after="00:00" --before="24:00"' \ - - -function gc() { - if ! __is_diff; then - echo "Nothing to commit, working tree clean" - return - fi - - if [[ "$@" != "" ]]; then - commit="$@" - else - echo "Enter commit message:" && read commit - fi - git commit -m "$commit" -} - -function __is_diff() { - ! git diff --quiet HEAD $REF -- $DIR -} - -function gdf() { - __is_diff && git diff HEAD $RED -- $DIR || echo "Repo is unchanged" -} diff --git a/zsh/zscripts/shortcuts.zsh b/zsh/zscripts/shortcuts.zsh deleted file mode 100755 index 214b7f7..0000000 --- a/zsh/zscripts/shortcuts.zsh +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/env zsh - -# TODO make this script more comprehensive to allow real aliases for directories -# Quick navigate to directories / open specific files -alias \ - cdc="cd ~/docs/src/programs" \ - cds="cd ~/docs/src/scripts" \ - cdw="cd ~/docs/src/sites" \ - vrc="vim ~/.config/nvim/init.vim" \ - xrc="cd ~/.config/x11" \ - zrc="cd ~/.config/zsh" \ - diff --git a/zsh/zscripts/terminalname.zsh b/zsh/zscripts/terminalname.zsh deleted file mode 100755 index 6e55d22..0000000 --- a/zsh/zscripts/terminalname.zsh +++ /dev/null @@ -1,8 +0,0 @@ -function xtitle () { - builtin print -n -- "\e]0;$@\a" -} - -# Updates the window title whenever a command is run -function precmd () { - xtitle "$(print -P ${USER}@${HOST} %~)" -} diff --git a/zsh/zscripts/termuxprompt.zsh b/zsh/zscripts/termuxprompt.zsh deleted file mode 100755 index 1442cc8..0000000 --- a/zsh/zscripts/termuxprompt.zsh +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env zsh - -if [ -n "$TERMUX_VERSION" ]; then - PS1="%B%F{green}[%F{blue}%U%~%u%F{green}]%f%b%(!.#.$) " - PS1OVERRIDE=1 - export ZPLUGINSDIR=~/.local/share/zsh/zplugins - export ZPLUGNOROOT=1 -fi diff --git a/zsh/zscripts/vicursor.zsh b/zsh/zscripts/vicursor.zsh deleted file mode 100755 index 3e4320d..0000000 --- a/zsh/zscripts/vicursor.zsh +++ /dev/null @@ -1,21 +0,0 @@ -#!/usr/bin/env zsh - -# Change cursor shape for different vi modes -# Copied from LARBS -if [ -n "$DISPLAY" ]; then - function zle-keymap-select () { - case $KEYMAP in - vicmd) echo -n '\e[1 q';; # block - viins|main) echo -n '\e[5 q';; # beam - esac - } - zle -N zle-keymap-select - zle-line-init() { - #zle -K viins # initiate `vi insert` as keymap (can be removed if `bindkey -V` has been set elsewhere) - echo -n "\e[5 q" - } - zle -N zle-line-init - echo -n '\e[5 q' # Use beam shape cursor on startup - preexec() { echo -n '\e[5 q' ;} # Use beam shape cursor for each new prompt -fi - diff --git a/zsh/zscripts/zplug.zsh b/zsh/zscripts/zplug.zsh deleted file mode 100755 index 27dc70f..0000000 --- a/zsh/zscripts/zplug.zsh +++ /dev/null @@ -1,136 +0,0 @@ -#!/usr/bin/env zsh - -local home=~ -local zplugs="${ZDOTDIR:-$home/.}${ZDOTDIR:+/}zplugs" # Declare all variables using `local` to keep them away from the interactive shell -local zplugins="${ZPLUGINSDIR:-$home/.local/share/zsh/zplugins}" -#[[ $EUID != 0 ]] && [ -z "$ZPLUGNOROOT" ] && local sudo=${SUDO-sudo} - -function __zplugInstall() { - touch "$zplugs" - local pluglist=( `\grep -v '#' "$zplugs"` ) - local confirm plug - shift - for plug in "$@"; do; pluglist+=(${plug}); done - - $sudo mkdir -p "$zplugins" - - for plug in ${pluglist[@]}; do - [ -d "$zplugins/$(basename -s'.git' "$plug")" ] && continue - if ! `$sudo git -C "$zplugins" clone "$plug" "$(basename -s'.git' "$plug")"`; then - # Runs if git has an error - printf "Remove \"$plug\"? [y|n]: " - read confirm - case $confirm in - y|yes) pluglist=(${pluglist#$plug}) && echo "Repo Deleted" ;; - *) echo "Repo Kept" ;; - esac - fi - echo - done - for plug in ${pluglist[@]}; do echo "$plug"; done | sort -u > "$zplugs" - echo "All plugins installed and saved to $zplugs!\nDone" -} - -function __zplugUninstall() { - local pluglist=( `cat "$zplugs"` ) pluglistbn=() - local confirm i plug plugids plugig - - [ -z "$pluglist" ] && echo "No packages are installed!" && return - - $sudo mkdir -p "$zplugins" - echo "Listing all packages in $zplugins ..." - for i in {1..${#pluglist[@]}}; do - pluglistbn[$i]="$(basename -s'.git' "${pluglist[$i]}")" - printf '%3d) %s\n' $i "${pluglistbn[$i]}" - done - - echo - printf "Choose zsh plugin(s) to remove: " - read plugids - [ -z "$plugids" ] && echo "No plugins selected\nAborting" && return - - echo "\nListing selected plugins:" - for plugid in $=plugids; do - if [ -z ${pluglist[$plugid]} ]; then - echo "Error: input \"$plugid\" is not a valid plugin identifier" - return - fi - echo "\t${pluglistbn[$plugid]}" - done - - printf "\nReally remove all of these plugins? [y|n]: " - read confirm - case $confirm in - y|yes) ;; - n|no) echo "Aborted" && return ;; - *) echo "Input not understood\nAborted" && return ;; - esac - for plugid in $=plugids; do - printf '\t' - $sudo rm -vrf "$zplugins/${pluglistbn[$plugid]}" - pluglist[$plugid]="" - done - for plug in ${pluglist[@]}; do echo "$plug"; done | sort -u > "$zplugs" - echo "\nDone" -} - -function __zplugUpgrade() { - local plugdir - $sudo mkdir -p "$zplugins" - echo "Upgrading all packages...\n" - for plugdir in "$zplugins"/*; do; - basename "$plugdir" - $sudo git -C "$plugdir" pull; - echo - done - echo "Done" -} - -function __zplugList() { - mkdir -p "$zplugins" - echo "Listing all packages...\n" - ls "$zplugins" | nl -s') ' -w3 - echo "\nDone" -} - -function __zplugHelp() { - echo "Usage: zplug [install/add/i|uninstall/remove/r|upgrade/update/u|list/l|help/h] - install, add, i [packages] : Install plugins from config file & add any new plugins - uninstall, remove, r : Interactively remove plugins - upgrade, update, u : Update all installed plugins - list, l : List all installed plugins - help, h : Show this help menu - - All plugins are listed in $zplugs - All plugins are installed in $zplugins - - To install a plugin, just put it in the zplug file and run \"zplug install\" - or just run \"zplug install [plugin]\" where [plugin] is a link to download the - plugin using git - - For instance, \"https://github.com/zdharma-continuum/fast-syntax-highlighting\" is - a valid plugin link for the fast-syntax-highlighting plugin. - - To use your plugins, just put \"zplugInitialize\" as the last line of your zshrc!" -} - -function zplug() { - local cmd=${1:-h} - case $cmd in - install|add|i) __zplugInstall $@ ;; - uninstall|remove|r) __zplugUninstall ;; - upgrade|update|u) __zplugUpgrade ;; - list|l) __zplugList ;; - help|h) __zplugHelp ;; - *) echo "zplug: input \"$1\" not recognized!" && __zplugHelp ;; - esac -} - -function zplugInitialize() { - local plugin - if ! [ -d "$zplugins" ] && [ -f "$zplugs" ]; then - echo "zplug installing plugins..." - __zplugInstall 0 # Put in some value since there is a shift - fi - for plugin in "$zplugins"/*/*.zsh; do source "$plugin"; done 2>/dev/null -} diff --git a/zsh/zscripts/zshcompmenu.zsh b/zsh/zscripts/zshcompmenu.zsh deleted file mode 100755 index 0d471a5..0000000 --- a/zsh/zscripts/zshcompmenu.zsh +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/env zsh - -# Basic auto/tab complete -autoload -U compinit -zstyle ':completion:*' menu select -zmodload zsh/complist -compinit -d "${XDG_CACHE_HOME:-$HOME/.config}/zcompdump" # Change where .zcompdump is stored -_comp_options+=(globdots) # Include hidden files. - -# Use ctrl-vi keys in tab complete menu -bindkey -M menuselect '^h' vi-backward-char -bindkey -M menuselect '^j' vi-down-line-or-history -bindkey -M menuselect '^k' vi-up-line-or-history -bindkey -M menuselect '^l' vi-forward-char -bindkey -v '^?' backward-delete-char - -# Options -setopt MENU_COMPLETE # Immediately insert first option from completion menu diff --git a/zsh/zshrc b/zsh/zshrc deleted file mode 100755 index 532c795..0000000 --- a/zsh/zshrc +++ /dev/null @@ -1,32 +0,0 @@ -#!/usr/bin/env zsh - -setopt +o NOMATCH # Non-existant wildcard matches won't produce an error - -# Zsh scripts (load general scripts, then host specific scripts, then scripts with ! prefix) (loaded later = higher priority) -for zscript in "$XDG_CONFIG_HOME/zsh/zscripts"{/[^\!]*.zsh,/hosts/*.$HOST.zsh,/!*.zsh}; do source "$zscript"; done 2>/dev/null - -# Colors! + Prompt -autoload -U colors && colors -[ -z "$PS1OVERRIDE" ] && PS1="%B%F{${colbr:-red}}[%F{${colname:-yellow}}%n%F{${colat:-green}}@%F{${colhost:-blue}}%m %F{${coldir:-magenta}}%U%~%u%F{${colbr:-red}}]%f%b%(!.#.$) " - -# Cd settings -setopt AUTO_CD # `cd` is implied when path is entered - -# History settings -HISTFILE="${ZHISTFILE:-$HOME/.zhistory}" -HISTSIZE=500 # Max lines of history loaded into memory for each zsh session -SAVEHIST=10000000 # Max lines of history saved to HISTFILE before overwriting -setopt EXTENDED_HISTORY # Save superfluous info with command to reduce disk writes when using INC_APPEND_HISTORY or SHARE_HISTORY -setopt HIST_IGNORE_DUPS # Successive duplicate entries ignored -setopt HIST_IGNORE_SPACE # Entries with leading space aren't stored in histfile -setopt HIST_REDUCE_BLANKS # Remove superfluous blank characters before saving -setopt INC_APPEND_HISTORY # Create entries after each command, not after zsh exits -setopt SHARE_HISTORY # Share history between zsh sessions - -# Input/output settings -setopt INTERACTIVE_COMMENTS # Comments won't be interpreted in an interactive shell - -# Disable bell -unsetopt BEEP - -zplugInitialize # Load zsh plugins using zplug; goes last |