aboutsummaryrefslogtreecommitdiff
path: root/dotfiles/.config/zsh/.zshrc
diff options
context:
space:
mode:
authorYaroslav <contact@yaroslavps.com>2020-04-02 14:22:19 +0300
committerYaroslav <contact@yaroslavps.com>2020-04-02 14:22:19 +0300
commit06ebba4c53dc2751a2aad1cbccb870bb7db6dc07 (patch)
tree3ed4a5006d7f66b54bcf7e32df2add4bcf9a5911 /dotfiles/.config/zsh/.zshrc
parent348fd5f7ffd4586b8599615dd453dcc61af3ace7 (diff)
downloadswayrice-06ebba4c53dc2751a2aad1cbccb870bb7db6dc07.tar.gz
swayrice-06ebba4c53dc2751a2aad1cbccb870bb7db6dc07.zip
HUGE home cleanup
Diffstat (limited to 'dotfiles/.config/zsh/.zshrc')
-rw-r--r--dotfiles/.config/zsh/.zshrc55
1 files changed, 9 insertions, 46 deletions
diff --git a/dotfiles/.config/zsh/.zshrc b/dotfiles/.config/zsh/.zshrc
index a597162..4a21004 100644
--- a/dotfiles/.config/zsh/.zshrc
+++ b/dotfiles/.config/zsh/.zshrc
@@ -1,8 +1,5 @@
# Colors and prompt
autoload -U colors && colors
-if [[ -f /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh ]]; then
- . /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
-fi
autoload -Uz vcs_info
precmd_vcs_info() { vcs_info }
@@ -55,50 +52,16 @@ function zle-keymap-select {
}
echo -ne '\e[5 q' # Use beam shape cursor on startup.
-preexec() { echo -ne '\e[5 q' ;} # Use beam shape cursor for each new prompt.
+printf "\033]2;%s\a" "$PWD" # Set terminal window title to current dir
+# Repeat for every new prompt
+preexec() {
+ echo -ne '\e[5 q'
+ printf "\033]2;%s\a" "$PWD"
+}
zle -N zle-keymap-select
-# Some aliases
-alias v="nvim"
-alias abook="abook -C $HOME/.config/abook/abookrc --datafile $HOME/Documents/contacts/addressbook"
-alias eslint="./node_modules/.bin/eslint"
-alias ls="ls -hN --color=auto --group-directories-first"
-weath() { curl wttr.in/$1 ;} # Check the weather (give city or leave blank).
-wintitle() { printf "\033]2;%s\a" "$1";}
-
-# Generic shortcuts
-alias music="ncmpcpp"
-alias clock="ncmpcpp -s clock"
-alias news="newsboat"
-alias files="ranger"
-alias audio="ncpamixer"
-alias calendar="calcurse"
-alias contacts="abook"
-alias calc="R --no-save"
+[ -f "$HOME/.config/zsh/shortcuts" ] && . "$HOME/.config/zsh/shortcuts"
-# Mounting drive shortcuts
-alias mnt="udisksctl mount -b"
-alias umnt="udisksctl unmount -b"
-alias dlock="udisksctl lock -b"
-alias dulock="udisksctl unlock -b"
-
-# Internet
-alias yt="youtube-dl --add-metadata -ic" # Download video link
-alias yta="youtube-dl --add-metadata -xic" # Download only audio
-alias YT="youtube-viewer"
-alias starwars="telnet towel.blinkenlights.nl"
-
-# Audio and Music
-alias mute="lmc mute"
-alias vu="lmc up"
-alias vd="lmc down"
-alias play="mpc toggle"
-alias next="mpc next"
-alias prev="mpc prev"
-alias pause="mpc pause"
-alias beg="mpc seek 0%"
-alias lilbak="mpc seek -10"
-alias lilfor="mpc seek +10"
-alias bigbak="mpc seek -120"
-alias bigfor="mpc seek +120"
+[ -f /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh ] &&
+ . /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh