.dotfiles

Posted on Oct 22, 2022
tl;dr: lazy dotfiles for slackers

.dotfiles

On the old site I used to keep some of my .dotfiles for configuration of stuff, so I could easily grab them and reuse them on every new box I touched, and also so others can find some reference material. Here’s the modern equivalents of what I’ve got.

.tmux.conf

Of all the things I can’t live without, tmux is one of the top ones. This config broadly remaps the ctrl+b behavior to react to ctrl+a and changes the theme to my favourite one….

Download here.

zsh

A few snippets more than a full example file. The first two live in my .zlogin file, and generate me a random password at every new shell and return my current (external) IP address. The latter live in my .zshrc, some useful aliases I have swapping out some utilities for ones I prefer…

.zlogin

echo -n "New Random Password: "
pwgen -1 32 -s

echo -n "Current external IP: "
curl https://wtfismyip.com/text

.zshrc

Mostly {Open,Free}BSD specific…

HISTFILE=~/.histfile
HISTSIZE=1000
SAVEHIST=1000
setopt appendhistory autocd beep notify
bindkey -v
zstyle :compinstall filename '${HOME}/.zshrc'

autoload -U promptinit
promptinit
prompt clint

alias ls="ls-go"  # go install github.com/acarl005/ls-go@latest or brew install acarl005/homebrew-formulas/ls-go
alias sudo=doas   # https://flak.tedunangst.com/post/doas-mastery
alias pflog="doas tcpdump -netttttvvi pflog0" # FreeBSD
alias pflog="doas tcpdump -n -e -ttt -i pflog0"
alias pftop="doas pftop"
alias pfinfo="doas pfctl -s info"
alias pfstat="doas pfctl -vvsr"

vim

Vim continues to irritate me - it’s so system/distro dependent what the behaviour is on a given system. This is my vimrc, which needs to either live in ~/.vimrc or ~/.vim/vimrc, dependent on a given system. Pasting, etc, drives me mad on a new machine, so this is one of the first things to get added.

Download here. This was generated via Vim Bootstrap - an excellent resource, and you may prefer to just generate your own!