# # ~/.bashrc # # If not running interactively, don't do anything [[ $- != *i* ]] && return # that ain't vimlike set -o vi bind -m vi-command 'Control-l: clear-screen' bind -m vi-insert 'Control-l: clear-screen' # prompt PS1='\[\e[32m\]\u@\h\[\e[0m\]:\[\e[34m\]\w\[\e[0m\] \$ ' # Source this file from git that expands PS1 stuff GIT_PS1_SHOWUPSTREAM='verbose name' GIT_PS1_SHOWDIRTYSTATE=true GIT_PS1_SHOWUNTRACKEDFILES=true #GIT_PS1_SHOWCOLORHINTS=true GIT_PS1_DESCRIBE_STYLE=branch source /etc/bash_completion.d/git-prompt.sh PS1='\[\e[01;32m\]\u@\h\[\e[0m\]:\[\e[01;34m\]\w\[\e[0m\]$(__git_ps1 "(%s)")\[\e[0m\]\$ ' # History settings: no duplicates, decent size HISTSIZE=10000 HISTFILESIZE=2000 HISTCONTROL=ignoredups # aliases alias python="python3" alias cp="cp -i" # confirm before overwriting something alias np='nano -w PKGBUILD' alias more="less" alias rofi='rofi -m 1' alias weather="curl wttr.in" alias ls="exa -lhg --group-directories-first" alias ll="exa -lhga --group-directories-first" alias vim="nvim" alias docs="python ~/scripts/stock_price.py -s docs" alias stock="python ~/scripts/stock_price.py -s " alias r="ranger" alias grep='grep --colour=auto' # expand path PATH=/usr/local/bin:/usr/bin/:/usr/sbin PATH=$PATH:~/.local/share # exports export EDITOR=/usr/bin/nvim export BROWSER=firefox # fzf export FZF_DEFAULT_OPTS='--layout=reverse --height=50% --preview-window=right:50%:border-sharp --border-label=" command preview " --border=double' # Set up fzf key bindings and fuzzy completion # Ctrl+R override for bash history # Alt-C overried to cd into selected directory eval "$(fzf --bash)" # Quick file finder with preview and open with vim (Ctrl+T override) bind '"\C-t": "fzf --preview \"cat {}\" < <(find . -type f) | xargs $EDITOR\n"' # kinda annoying tbh # pfetch || neofetch || fastfetch