diff options
Diffstat (limited to 'zsh')
-rw-r--r-- | zsh/.zlogout | 2 | ||||
-rw-r--r-- | zsh/.zprofile | 6 | ||||
-rw-r--r-- | zsh/.zshenv | 78 | ||||
-rw-r--r-- | zsh/.zshrc | 79 |
4 files changed, 165 insertions, 0 deletions
diff --git a/zsh/.zlogout b/zsh/.zlogout new file mode 100644 index 0000000..55a747a --- /dev/null +++ b/zsh/.zlogout @@ -0,0 +1,2 @@ +killall pipewire +rm -rf /tmp/xorg-awake diff --git a/zsh/.zprofile b/zsh/.zprofile new file mode 100644 index 0000000..1eae5e7 --- /dev/null +++ b/zsh/.zprofile @@ -0,0 +1,6 @@ +#export GDK_DPI_SCALE=0.7 + +#gnome_schema=org.gnome.desktop.interface +# +#gsettings set $gnome_schema gtk-theme 'Plata-Noir-Compact' +#gsettings set $gnome_schema icon-theme 'Papirus-Dark' diff --git a/zsh/.zshenv b/zsh/.zshenv new file mode 100644 index 0000000..e48fa2b --- /dev/null +++ b/zsh/.zshenv @@ -0,0 +1,78 @@ +typeset -U PATH path + +unset HISTFILE + +# Other XDG paths +export XDG_DATA_HOME=${XDG_DATA_HOME:="$HOME/.local/share"} +export XDG_CACHE_HOME=${XDG_CACHE_HOME:="$HOME/.cache"} +export XDG_CONFIG_HOME=${XDG_CONFIG_HOME:="$HOME/.config"} + +# Doesn't seem to work +export ANDROID_SDK_HOME="$XDG_CONFIG_HOME"/android +export ANDROID_AVD_HOME="$XDG_DATA_HOME"/android/ +export ANDROID_EMULATOR_HOME="$XDG_DATA_HOME"/android/ +export ADB_VENDOR_KEY="$XDG_CONFIG_HOME"/android + +# Disable files +export LESSHISTFILE=- + +# Fixing Paths +export ATOM_HOME="$XDG_DATA_HOME"/atom +export XINITRC="$XDG_CONFIG_HOME"/X11/xinitrc +export XSERVERRC="$XDG_CONFIG_HOME"/X11/xserverrc +export GEM_SPEC_CACHE="$XDG_DATA_HOME/ruby/specs" +export GEM_HOME="$XDG_DATA_HOME/ruby/gems" +export NPM_CONFIG_USERCONFIG=$XDG_CONFIG_HOME/npm/npmrc +export GOPATH="$XDG_DATA_HOME"/go +export GNUPGHOME="$XDG_DATA_HOME"/gnupg +export GRADLE_USER_HOME="$XDG_DATA_HOME"/gradle +export NUGET_PACKAGES="$XDG_CACHE_HOME"/NuGetPackages +export RXVT_SOCKET="$XDG_RUNTIME_DIR"/urxvtd +export _JAVA_OPTIONS=-Djava.util.prefs.userRoot="$XDG_CONFIG_HOME"/java +export GTK2_RC_FILES="$XDG_CONFIG_HOME"/gtk-2.0/gtkrc +export ZDOTDIR=$HOME/.config/zsh +#export HISTFILE="$XDG_DATA_HOME"/zsh/history +export CARGO_HOME="$XDG_DATA_HOME"/cargo +export WEECHAT_HOME="$XDG_CONFIG_HOME"/weechat +export PASSWORD_STORE_DIR="$XDG_DATA_HOME"/pass +export NOTMUCH_CONFIG="$XDG_CONFIG_HOME"/notmuch/notmuchrc +export NMBGIT="$XDG_DATA_HOME"/notmuch/nmbug +export WINEROOT="$XDG_DATA_HOME"/wineprefixes +export WINEPREFIX="$WINEROOT"/default + +export MPD_HOST="$XDG_CONFIG_HOME/mpd/socket" + +# Scaling +export QT_AUTO_SCREEN_SCALE_FACTOR=0 +export QT_SCALE_FACTOR=1 +export QT_SCREEN_SCALE_FACTORS="1;1;1" +export GDK_SCALE=1 +export GDK_DPI_SCALE=1 + +# Theming +export QT_QPA_PLATFORMTHEME=qt5ct +export GTK_THEME=Sweet-mars-v40 + +# Configure apps +export BEMENU_OPTS="-H 24" + +# Fix wayland stuff +export MOZ_ENABLE_WAYLAND=1 +export XKB_DEFAULT_OPTIONS=caps:escape +export XDG_CURRENT_DESKTOP=Unity + +# Default Apps +export EDITOR="nvim" +export READER="zathura" +export VISUAL="nvim" +export TERMINAL="st" +export BROWSER="browser" +export VIDEO="mpv" +export IMAGE="sxiv" +export OPENER="xdg-open" +export PAGER="less" + +# KSH +export ENV="$XDG_CONFIG_HOME/kshrc" + +export PATH="$HOME/.local/volsv:$HOME/.local/bin/scripts:$HOME/.local/bin/dwmblocks:$HOME/.local/bin/testing:$CARGO_HOME/bin:$GOPATH/bin:$HOME/.local/bin:/opt/REAPER:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin" diff --git a/zsh/.zshrc b/zsh/.zshrc new file mode 100644 index 0000000..1c13e80 --- /dev/null +++ b/zsh/.zshrc @@ -0,0 +1,79 @@ +HISTFILE="$ZDOTDIR"/hist +SAVEHIST=1000 +HISTSIZE=1000 +setopt APPEND_HISTORY +setopt HIST_FIND_NO_DUPS +setopt HIST_EXPIRE_DUPS_FIRST +setopt HIST_VERIFY +setopt HIST_IGNORE_DUPS +setopt INC_APPEND_HISTORY +setopt HIST_REDUCE_BLANKS + +if [ -f "$XDG_CONFIG_HOME"/sh/aliases ]; then + source "$XDG_CONFIG_HOME"/sh/aliases +fi +if [ -f "$XDG_CONFIG_HOME"/sh/functions ]; then + source "$XDG_CONFIG_HOME"/sh/functions +fi + +bindkey "^?" backward-delete-char + +# bindkey -v + +if [ "$TERM" = "st-256color" ] || [ "$TERM" = "xterm-256color" ]; then + function zle-line-init () { echoti smkx } + function zle-line-finish () { echoti rmkx } + + zle -N zle-line-init + zle -N zle-line-finish +fi + +which pacman >/dev/null && COLOR1="cyan" +which apt >/dev/null && COLOR1="green" +which syspatch >/dev/null && COLOR1="red" + +MYPROMPT='%B%F{'"$COLOR1"'}[%n@%m]:%f%F{white}%~%f%F{'"$COLOR1"'}%#%f%b ' +function zle-line-init zle-keymap-select { + VIM_PROMPT="%B%F{blue}[%n@%m]:%f%F{white}%~%f%F{blue}%#%f%b " + PS1="${${KEYMAP/vicmd/$VIM_PROMPT}/main/$MYPROMPT}" + #PS1="$PROMPT $KEYMAP" + zle reset-prompt +} + +zle -N zle-line-init +zle -N zle-keymap-select +export KEYTIMEOUT=1 + +autoload -Uz compinit promptinit +compinit -d $CONFIG/zcompdump +promptinit +autoload -Uz up-line-or-beginning-search down-line-or-beginning-search +zle -N up-line-or-beginning-search +zle -N down-line-or-beginning-search + +zstyle ':completion:*' menu select +zstyle ':completion::complete:*' gain-privileges 1 +zstyle ':completion:*' rehash true + +setopt COMPLETE_ALIASES +setopt AUTO_CD + +typeset -g -A key + +key[Up]="${terminfo[kcuu1]}" +key[Down]="${terminfo[kcud1]}" +key[Left]="${terminfo[kcub1]}" +key[Right]="${terminfo[kcuf1]}" +key[Shift-Tab]="${terminfo[kcbt]}" +key[Delete]="${terminfo[kdch1]}" + +[[ -n "${key[Up]}" ]] && bindkey -- "${key[Up]}" up-line-or-beginning-search +bindkey -- '^[[A' up-line-or-beginning-search +bindkey -- '^[[B' down-line-or-beginning-search +[[ -n "${key[Down]}" ]] && bindkey -- "${key[Down]}" down-line-or-beginning-search +[[ -n "${key[Left]}" ]] && bindkey -- "${key[Left]}" backward-char +[[ -n "${key[Right]}" ]] && bindkey -- "${key[Right]}" forward-char +[[ -n "${key[Shift-Tab]}" ]] && bindkey -- "${key[Shift-Tab]}" reverse-menu-complete +[[ -n "${key[Delete]}" ]] && bindkey -- "${key[Delete]}" delete-char + +#eval "$(starship init zsh)" |