88 lines
2.1 KiB
Bash
88 lines
2.1 KiB
Bash
# if [ $VTE_VERSION ]; then
|
|
# source /etc/profile.d/vte.sh
|
|
# __vte_osc7
|
|
# fi
|
|
if [[ $TERMINAL == urxvt ]] || [[ $TERM == xterm ]] || [[ $TERM == screen ]]; then
|
|
export TERM="xterm-256color"
|
|
fi
|
|
|
|
fpath=(~/projects/scripts/completions/ $fpath)
|
|
|
|
# zplug management
|
|
source ~/.zplug/init.zsh
|
|
|
|
zplug "zplug/zplug", hook-build:'zplug --self-manage'
|
|
zplug "denysdovhan/spaceship-zsh-theme", use:spaceship.zsh, as:theme
|
|
# zplug "dracula/zsh", as:theme
|
|
zplug "zsh-users/zsh-autosuggestions"
|
|
zplug "zsh-users/zsh-completions"
|
|
zplug "zsh-users/zsh-syntax-highlighting", defer:3
|
|
zplug "plugins/pass", from:oh-my-zsh
|
|
|
|
if ! zplug check; then
|
|
zplug install
|
|
fi
|
|
|
|
zplug load
|
|
|
|
# Theme settings
|
|
export SPACESHIP_TIME_SHOW=true
|
|
export SPACESHIP_CHAR_SYMBOL="> "
|
|
export SPACESHIP_BATTERY_SHOW=false
|
|
|
|
# Do menu-driven completion.
|
|
zstyle ':completion:*' menu select
|
|
zstyle ':completion::complete:*' use-cache 1
|
|
|
|
# Lines configured by zsh-newuser-install
|
|
HISTFILE=~/.histfile
|
|
HISTSIZE=2000
|
|
SAVEHIST=1000
|
|
setopt beep
|
|
bindkey -e
|
|
# End of lines configured by zsh-newuser-install
|
|
# The following lines were added by compinstall
|
|
zstyle :compinstall filename '~/.zshrc'
|
|
|
|
autoload -Uz compinit
|
|
# End of lines added by compinstall
|
|
|
|
# Alias definition
|
|
# Paranoia
|
|
alias rm="rm -i"
|
|
alias delete="rm -I"
|
|
alias mv="mv -i"
|
|
alias cp="cp -ip"
|
|
|
|
alias ls="ls -F --color=auto"
|
|
alias la="ls -FAhl --color=auto"
|
|
alias ll="ls -Flh --color=auto"
|
|
alias lt="ls -Flhart --color=auto"
|
|
alias sl="exa -Fal"
|
|
alias lesr="less -R"
|
|
alias ip="ip -c"
|
|
#alias man="info"
|
|
alias filesize="stat -c '%s'"
|
|
|
|
alias mirror="~/mirrors/websites/mirror"
|
|
alias qledger="gpg -o - --decrypt ~/notes/ledger.dat.gpg | ledger -f - "
|
|
alias ytda="youtube-dl -f 'bestaudio[ext=webm]/bestaudio'"
|
|
alias ytdv="youtube-dl -f 'bestvideo[ext=webm]+bestaudio[ext=webm]/bestvideo+bestaudio'"
|
|
alias mpa="mpv --no-vid --loop-playlist=inf"
|
|
alias flame="perf script | ~/builds/FlameGraph/stackcollapse-perf.pl | ~/builds/FlameGraph/flamegraph.pl > flamegraph.svg"
|
|
alias p6="perl6"
|
|
|
|
function cheat() {
|
|
if [ -n "$1" ]
|
|
then
|
|
curl "https://cheat.sh/{$@}"
|
|
else
|
|
curl "https://cheat.sh"
|
|
fi
|
|
}
|
|
|
|
# I need my fortune's
|
|
if hash fortune 2>/dev/null; then
|
|
fortune -a
|
|
fi
|