Move scripts to own folder
This commit is contained in:
parent
9204716d04
commit
5d9e05b202
24 changed files with 17 additions and 1031 deletions
|
|
@ -8,25 +8,22 @@ function get_path {
|
|||
SCRIPTPATH=`dirname $SCRIPT`
|
||||
}
|
||||
|
||||
function user_config {
|
||||
read -p 'Install the script for a normal user or root account? [user/root]: ' USER
|
||||
read -p 'Install the script for a normal user or root account? [user/root]: ' USER
|
||||
|
||||
if [[ "$USER" == "user" ]]; then
|
||||
get_path
|
||||
mkdir $HOME/.vim
|
||||
ln -sf $SCRIPTPATH/{.bashrc,vim/.vimrc,tmux/.tmux.conf,.profile} $HOME/;
|
||||
ln -sf $SCRIPTPATH/vim/colors $HOME/.vim/
|
||||
echo 'Linking configuration files done'
|
||||
elif [[ "$USER" == "root" ]]; then
|
||||
get_path
|
||||
mkdir /root/.vim
|
||||
ln -sf $SCRIPTPATH/{.bashrc,vim/.vimrc,tmux/.tmux.conf,.profile} /root/
|
||||
ln -sf $SCRIPTPATH/vim/colors /root/.vim/
|
||||
echo 'Linking configuration files done'
|
||||
else
|
||||
echo 'No selection was made'
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
if [[ "$USER" == "user" ]]; then
|
||||
get_path
|
||||
mkdir $HOME/.vim
|
||||
ln -sf $SCRIPTPATH/{.bashrc,vim/.vimrc,.tmux.conf,.profile} $HOME/;
|
||||
ln -sf $SCRIPTPATH/vim/colors $HOME/.vim/
|
||||
echo 'Linking configuration files done'
|
||||
elif [[ "$USER" == "root" ]]; then
|
||||
get_path
|
||||
mkdir /root/.vim
|
||||
ln -sf $SCRIPTPATH/{.bashrc,vim/.vimrc,.tmux.conf,.profile} /root/
|
||||
ln -sf $SCRIPTPATH/vim/colors /root/.vim/
|
||||
echo 'Linking configuration files done'
|
||||
else
|
||||
echo 'No selection was made'
|
||||
exit 1
|
||||
fi
|
||||
|
||||
user_config
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue