From b7ef29a8886a57aadb787807a7c6cf74c1f0ed3a Mon Sep 17 00:00:00 2001 From: anand Date: Wed, 17 Dec 2025 15:57:55 +0530 Subject: Nixos --- shell/zshrc | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100755 shell/zshrc (limited to 'shell/zshrc') diff --git a/shell/zshrc b/shell/zshrc new file mode 100755 index 0000000..4bac285 --- /dev/null +++ b/shell/zshrc @@ -0,0 +1,81 @@ +# The following lines were added by compinstall + +fpath=(~/.zsh/completion/ $fpath) + +autoload -Uz compinit; compinit +source /home/anand/github/fzf-tab/fzf-tab.plugin.zsh +# For zsh completion +export PATH=/usr/bin/aws_completer:$PATH +autoload bashcompinit && bashcompinit +complete -C "$(which aws_completer)" aws + +autoload -Uz edit-command-line +zle -N edit-command-line +zstyle ':completion:*' completer _expand _complete _ignored +zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}' +zstyle :compinstall filename '/home/anand/.zshrc' + +autoload -Uz tetriscurses +autoload -Uz colors && colors + +alias cls="clear" +alias battery='upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep percentage;upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep "time"' +alias start_venv='source ~/Documents/prog/python/.venv/bin/activate' +alias ls='[ $[$RANDOM % 1000] = 0 ] && sl || eza --icons="always"' +alias hms='home-manager switch -f ~/dots/home.nix' +alias feh='feh --info "echo %n"' +please() { + sudo $(fc -ln -1) +} +alias cat='bat' +alias ..='cd ..' +alias cp='cp -i' +alias rm='rm -i' +alias mv='mv -i' +alias df='df -h' +alias ll='eza -lF --icons="always"' +alias lla='eza -AlF --icons="always"' +alias la='eza -AF --icons="always"' + +alias feh='feh --info "echo %n"' +alias updateserver='rsync -avz --delete -e "ssh -i ~/.ssh/mailaws.pem" --rsync-path="sudo rsync" ~/Documents/prog/website/ admin@heresanandp.in:/var/www/website/' + +export EDITOR='/home/anand/.nix-profile/bin/nvim' +export VISUAL='/home/anand/.nix-profile/bin/nvim' +export HISTCONTROL=ignoreboth + +# Temporary fix +alias man='batman' + +# End of lines added by compinstall +# Lines configured by zsh-newuser-install +HISTFILE=~/.histfile +HISTSIZE=1000 +SAVEHIST=1000 +setopt notify +unsetopt nomatch autocd beep extendedglob +bindkey -v + +# Plugins +source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh +source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh +source /usr/share/zsh/plugins/zsh-history-substring-search/zsh-history-substring-search.zsh +fpath=(/home/anand/github/zsh-completions/src $fpath) + +# fzf +source <(fzf --zsh) +source <(jj util completion zsh) + +# Binds for history search +bindkey '^[[A' history-substring-search-up +bindkey '^[[B' history-substring-search-down + +eval "$(zoxide init zsh)" + +## [Completion] +## Completion scripts setup. Remove the following line to uninstall +[[ -f /home/anand/.dart-cli-completion/zsh-config.zsh ]] && . /home/anand/.dart-cli-completion/zsh-config.zsh || true +## [/Completion] + +eval "$(starship init zsh)" +bindkey "^X^E" edit-command-line -- cgit v1.2.3