From 7cc6ff35cc277c22a8832a4feec97421ddd9e3d4 Mon Sep 17 00:00:00 2001 From: Travis Heller Date: Wed, 30 Sep 2015 11:51:53 -0700 Subject: [PATCH] Added a check to see if the file has already been installed. --- README.rst | 2 ++ tmux-mem-cpu-load.plugin.zsh | 13 ++++++++----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/README.rst b/README.rst index 96c9fc3..fa46470 100644 --- a/README.rst +++ b/README.rst @@ -83,7 +83,9 @@ Install Build and Install Using [Antigen](https:/github.com/zsh-users/antigen) -------- + Include the bundle in your ``.zshrc`` + ``antigen bundle thewtex/tmux-mem-cpu-load`` Configuring tmux_ diff --git a/tmux-mem-cpu-load.plugin.zsh b/tmux-mem-cpu-load.plugin.zsh index 2b03b22..a6f18cc 100644 --- a/tmux-mem-cpu-load.plugin.zsh +++ b/tmux-mem-cpu-load.plugin.zsh @@ -1,7 +1,10 @@ # vim: tabstop=2 shiftwidth=2 expandtab textwidth=80 linebreak wrap -pushd ${0:a:h} #Pushd to the directory where this file is located. -cmake . -make -sudo make install -popd +if [ ! -s /usr/local/bin/tmux-mem-cpu-load ]; +then + pushd ${0:a:h} #Pushd to the directory where this plugin is located. + cmake . + make + sudo make install + popd +fi