Add tmux plugin manager auto setup

This commit is contained in:
Marty Oehme 2019-02-04 15:27:49 +01:00
parent 410c1177e0
commit 8c5bf02181
3 changed files with 21 additions and 10 deletions

View file

@ -0,0 +1,13 @@
# Clone tmux plugin manager if not existing
if [[ -z "$TPM_PARENT_DIR" ]]; then
TPM_PARENT_DIR=$HOME
fi
if [[ ! -f $TPM_PARENT_DIR/.tmux/plugins/tpm/tpm ]]; then
if [[ ! -d "$TPM_PARENT_DIR" ]]; then
mkdir -p "$TPM_PARENT_DIR"
fi
pushd $TPM_PARENT_DIR
git clone https://github.com/tmux-plugins/tpm ./.tmux/plugins/tpm
popd
fi
unset TPM_PARENT_DIR