dot-zshrc (1749B)
1 # system env 2 export PATH=~/.bin:~/.local/bin:$PATH 3 export LC_ALL=ru_RU.UTF-8 4 export LANG=ru_RU.UTF-8 5 export LANGUAGE=ru_RU.UTF-8 6 7 8 # personal info 9 export NAME='Anton Konyahin' 10 export EMAIL='me@konyahin.xyz' 11 12 13 # programs 14 export EDITOR='nvi' 15 export ALTERNATE_EDITOR='emacs -nw' 16 export PAGER=less 17 export BROWSER=open 18 export PASSWORD_STORE_DIR="$HOME/data/pass" 19 export TEMPL_DIR="$HOME/projects/templates" 20 21 alias z=zathura 22 alias e='$EDITOR' 23 alias em='$ALTERNATE_EDITOR' 24 alias v=nview 25 alias nb='newsboat && bookmark count' 26 alias m='mutt && isync' 27 alias isync='mbsync -c ~/.config/.mbsyncrc -a && mfilter ~/data/mail/fastmail' 28 alias l='ls -p -A' 29 alias lr='l -R' 30 31 32 # configs editing 33 alias evi='$EDITOR ~/.nexrc' 34 alias enb='$EDITOR ~/.newsboat/config' 35 alias enbu='$EDITOR ~/.newsboat/urls' 36 alias esh='$EDITOR ~/.zshrc' 37 alias edot='$EDITOR "$(find ~/dotfiles -type f ! -path "*.git/*" | fzf)"' 38 39 40 # text editing 41 alias ef='$EDITOR $(find . | fzf)' 42 alias et='$EDITOR -t $(cat tags | awk "{print \$1}" | fzf)' 43 44 45 # usefull functions 46 alias gpush='git remote | xargs -n 1 git push' 47 48 fzf-in () { 49 found=$(find . -not -path "*.git*" | fzf) 50 [ -d "$found" ] && cd "$found" && return 51 [ -f "$found" ] && $EDITOR "$found" && return 52 } 53 alias /=fzf-in 54 alias //='cd ~/; /' 55 56 me () { 57 $EDITOR $(make 2>&1 | grep '^.*\.[ch]:' | fzf | awk -F: '{printf "-c %s %s\n", $2, $1}') 58 } 59 60 jp () { 61 projects=$(find ~/projects/ -type d -maxdepth 1 -mindepth 1 ! -name konyahin) 62 selected=$(echo "$projects" | fzf) 63 [ -n "$selected" ] && cd "$selected" 64 } 65 66 67 # zsh specific 68 source ~/.profile 69 alias reload='source ~/.zshrc' 70 71 setopt EXTENDED_HISTORY 72 setopt inc_append_history_time 73 74 source /opt/homebrew/share/zsh-autosuggestions/zsh-autosuggestions.zsh 75 source <(fzf --zsh) 76