Config changes after 3 years of work
Jun 16, 2020
Most of my linux configuration I still use today was set in college. My first three years of work led to relatively few configuration changes. Here they are:
vimrc
Now necessary when sharing repos with people who don’t have trailing newlines
configured. I spent probably about a year and a half using git add -p
to
manually exclude trailing newline changes before I figured out this might be
configurable.
set nofixendofline " stop adding trailing newlines
zshrc
I haven’t started using fish shell yet, but I did enable syntax highlighting.
plugins=(z sudo zsh-syntax-highlighting)
And, now that I worked on feature/PR branches, I wanted something to display my git branch in my terminal.
# Print git branch in right prompt
setopt PROMPT_SUBST
rprompt() {
br=$(git rev-parse --abbrev-ref HEAD 2>/dev/null || true)
echo -n "%F{green}%~%f"
[ -n "$br" ] && echo -n " %F{blue}$br%f"
}
export RPROMPT='$(rprompt)'
Other
I started using rg
instead of grep
. I’m still using vim (no VS Code yet).