summaryrefslogtreecommitdiff
path: root/zsh
diff options
context:
space:
mode:
authorMatt Turner <mattst88@framework.mattst88.com>2023-03-06 11:12:20 -0500
committerMatt Turner <mattst88@gmail.com>2023-03-06 11:18:37 -0500
commit01204fff758637398ce3a9d2b6ca20038016e45b (patch)
treeec1e65f28390437a4c6a07cbf6a507304cc1bd8d /zsh
parente83765747e2f4411189dbae392b5e197fdf8744b (diff)
Rearrange for better usage with GNU stow
Diffstat (limited to 'zsh')
-rw-r--r--zsh/.zshrc68
1 files changed, 68 insertions, 0 deletions
diff --git a/zsh/.zshrc b/zsh/.zshrc
new file mode 100644
index 0000000..bdeb4f7
--- /dev/null
+++ b/zsh/.zshrc
@@ -0,0 +1,68 @@
+#!/bin/zsh
+
+autoload -U compinit
+compinit
+
+zstyle ':completion:*:descriptions' format '%U%B%d%b%u'
+zstyle ':completion:*:warnings' format '%BSorry, no matches for: %d%b'
+
+unsetopt correctall
+unsetopt equals
+
+autoload -U promptinit
+promptinit
+
+prompt gentoo
+
+export HISTSIZE=5000
+export HISTFILE="$HOME/.history"
+export SAVEHIST=$HISTSIZE
+setopt hist_ignore_all_dups
+setopt hist_ignore_space
+setopt share_history
+
+# Breaks "eix ^asdf"
+# setopt extendedglob
+
+bindkey "^[[H" beginning-of-line
+bindkey "^[[1~" beginning-of-line
+bindkey "^[OH" beginning-of-line
+bindkey "^[[F" end-of-line
+bindkey "^[[4~" end-of-line
+bindkey "^[OF" end-of-line
+bindkey ' ' magic-space # also do history expansion on space
+bindkey '^R' history-incremental-search-backward
+
+bindkey "^[[1;5C" forward-word
+bindkey "^[[1;5D" backward-word
+
+bindkey '^[[Z' reverse-menu-complete
+
+# Make the delete key (or Fn + Delete on the Mac) work instead of outputting a ~
+bindkey '^?' backward-delete-char
+bindkey "^[[3~" delete-char
+bindkey "^[3;5~" delete-char
+bindkey "\e[3~" delete-char
+
+export PATH=:$PATH:~/bin
+
+alias pkgdiff="pkgdiff-mg"
+alias grpe="grep"
+alias gti="git"
+alias sl="ls"
+
+unset SSH_AGENT_PID
+if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
+ export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
+fi
+export GPG_TTY=$(tty)
+
+FILES=(
+ /etc/profile.d/autojump.sh
+ /etc/profile.d/vte-2.91.sh
+ /usr/share/fzf/key-bindings.zsh
+)
+
+for file in "${FILES[@]}"; do
+ [[ -e $file ]] && . "${file}"
+done