···11+#!/bin/sh
22+33+PS1='$(prompt) \$ '
44+55+# make history infinite, dedup'd, and sync'd between terms
66+HISTFILESIZE=infinite
77+HISTCONTROL=ignoredups:erasedups
88+shopt -s histappend
99+PROMPT_COMMAND="${PROMPT_COMMAND:+$PROMPT_COMMAND$'\n'}history -a; history -c; history -r"
1010+1111+# extend pa for git stuffs
1212+# meh i don't like this at all tbh
1313+pa() {
1414+ case $1 in
1515+ g)
1616+ cd "${PA_DIR:=${XDG_DATA_HOME:=$HOME/.local/share}/pa}"
1717+ git pull
1818+ git add --all
1919+ git commit -m '*'
2020+ git push
2121+ cd -
2222+ ;;
2323+2424+ *)
2525+ command pa "$@"
2626+ ;;
2727+ esac
2828+}
2929+3030+# yep still needed
3131+if ls --version 2>&1 | grep -i gnu > /dev/null
3232+then
3333+ alias ls='ls --color=auto '
3434+elif ls --version 2>&1 | grep -i busybox > /dev/null
3535+then
3636+ alias ls='ls --color=auto '
3737+fi
3838+3939+if [ -z "${SSH_AGENT_PID}" ]
4040+then
4141+ if ! [ -e /tmp/ssh-agent-$USER ]
4242+ then
4343+ ssh-agent 2>/dev/null >/tmp/ssh-agent-$USER
4444+ fi
4545+ . /tmp/ssh-agent-$USER >/dev/null
4646+fi
4747+4848+# launch alacritty with no GPU support if on old thinkpad
4949+# TODO: maybe irrelevant when using foot
5050+if [ "$(hostname)" == 'nyx' ]; then
5151+ export LIBGL_ALWAYS_SOFTWARE=1
5252+fi
5353+5454+if [ "$(hostname)" == 'nostromo' ]; then
5555+ if ! pgrep syncthing &> /dev/null; then
5656+ syncthing --no-browser > /dev/null &
5757+ fi
5858+fi
5959+6060+if [ "$TERM" = "alacritty" ]; then
6161+ alias ssh='TERM=xterm-256color ssh'
6262+fi