Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Allow installing config from any directory (master) #38

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 11 additions & 9 deletions install.sh
Original file line number Diff line number Diff line change
@@ -1,28 +1,30 @@
#!/bin/bash

# Author arthurkiller
# email arthur-lee@qq.com
# data 2017-1-4
# this shell is used for initialize the tmux-config

#!/bin/bash

trap exit ERR
if [ -d $HOME/.tmux ]
if [ -d ~/.tmux ]
then
echo .tmux already exist
mv $HOME/.tmux $HOME/.tmux.bak
mv ~/.tmux ~/.tmux.bak
fi

if [ -e $HOME/.tmux.conf ]
if [ -e ~/.tmux.conf ]
then
echo .tmux.conf already exist
mv $HOME/.tmux.conf $HOME/.tmux.conf.bak
mv ~/.tmux.conf ~/.tmux.conf.bak
fi

cp -r $HOME/tmux-config $HOME/.tmux
ln -s $HOME/.tmux/.tmux.conf $HOME/.tmux.conf
cp -r . ~/.tmux
ln -s ~/.tmux/.tmux.conf ~/.tmux.conf

cd ~/.tmux && git submodule init && git submodule update
pushd ~/.tmux && git submodule init && git submodule update

cd ~/.tmux/vendor/tmux-mem-cpu-load && cmake . && make && sudo make install

tmux source-file ~/.tmux.conf

popd