Created
May 14, 2016 22:34
-
-
Save gretel/5c288fbbdf782c6f34755558ac754d0d to your computer and use it in GitHub Desktop.
openbsd login shell profile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# $OpenBSD: dot.profile | |
# | |
# gretel's sh/ksh initialization | |
trap '. $HOME/.logout; exit' 0 | |
escape=$(print '\033') | |
ctrla=$(print '\001') | |
PS1=$(print '\001\015') | |
PS1=$PS1$ctrla$escape'[$(($? ? 31 : 32))m'$ctrla | |
PS1=$PS1'[\u@\h \w]' | |
PS1=$PS1$ctrla$escape'[0m'$ctrla' ' | |
export PS1 | |
alias ls='ls -aFls' | |
alias mx_log='sudo tail -f /var/log/maillog' | |
alias msg_log='tail -f /var/log/messages' | |
alias pf_log='sudo tcpdump -eetttvvvvi pflog0' | |
alias upd_tbl='sudo /usr/local/bin/upd_table.sh direct_dst /etc/pf_direct_dst.table' | |
alias upd_pf='sudo pfctl -n -f /etc/pf.conf && sudo pfctl -f /etc/pf.conf' | |
alias flush_pf='sudo pfctl -n -f /etc/pf.conf && sudo pfctl -F all -f /etc/pf.conf' | |
alias top='top -S -s 1 -o cpu' | |
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R6/bin:/usr/local/bin:/usr/local/sbin | |
export PATH HOME TERM | |
PKG_PATH=http://ftp.bytemine.net/pub/OpenBSD/snapshots/packages/amd64/ | |
export PKG_PATH | |
export GOPATH=$HOME/.go | |
PATH="${HOME}/bin:${PATH}:${GOPATH}/bin" | |
export PATH | |
if [ -z "$SSH_AUTH_SOCK" ]; then | |
if ! pgrep -qxu $(id -u) ssh-agent; then | |
ssh-agent -s -t 60 | grep -v ^echo > ~/.ssh-agent.sh | |
fi | |
. ~/.ssh-agent.sh | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment