Remove plugin entries
This commit is contained in:
parent
c3a9ae89a0
commit
e02805dbb3
1 changed files with 2 additions and 21 deletions
|
|
@ -1,12 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# Setup script for vim & tmux
|
# Setup script for vim & tmux
|
||||||
|
|
||||||
if [ $EUID != 0 ]; then
|
|
||||||
echo "This script needs sudo priveleges in order to install Curl"
|
|
||||||
echo "Exiting..."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
function get_path {
|
function get_path {
|
||||||
# Get the full path of a file
|
# Get the full path of a file
|
||||||
SCRIPT=`realpath $0`
|
SCRIPT=`realpath $0`
|
||||||
|
|
@ -16,29 +10,17 @@ function get_path {
|
||||||
|
|
||||||
function user_config {
|
function user_config {
|
||||||
|
|
||||||
CURL='dpkg-query -l | grep curl | wc -l'
|
|
||||||
if [ "$CURL" > 0 ]; then
|
|
||||||
echo 'Curl not installed, installing....'
|
|
||||||
apt-get install -y curl
|
|
||||||
fi
|
|
||||||
|
|
||||||
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
|
if [[ "$USER" == "user" ]]; then
|
||||||
curl -fLo /home/$SUDO_USER/.vim/autoload/plug.vim --create-dirs \
|
|
||||||
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
|
|
||||||
|
|
||||||
get_path
|
get_path
|
||||||
ln -s $SCRIPTPATH/vim/{.vimrc,.tmux.conf} /home/$SUDO_USER/;
|
ln -s $SCRIPTPATH/{vim/.vimrc,tmux/.tmux.conf} /home/$SUDO_USER/;
|
||||||
ln -s $SCRIPTPATH/vim/colors /home/$SUDO_USER/.vim/
|
ln -s $SCRIPTPATH/vim/colors /home/$SUDO_USER/.vim/
|
||||||
chown -R $SUDO_USER:$SUDO_USER /home/$SUDO_USER/.vim
|
chown -R $SUDO_USER:$SUDO_USER /home/$SUDO_USER/.vim
|
||||||
echo 'Linking configuration files done'
|
echo 'Linking configuration files done'
|
||||||
elif [[ "$USER" == "root" ]]; then
|
elif [[ "$USER" == "root" ]]; then
|
||||||
curl -fLo /root/.vim/autoload/plug.vim --create-dirs \
|
|
||||||
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
|
|
||||||
|
|
||||||
get_path
|
get_path
|
||||||
ln -s $SCRIPTPATH/vim/{.vimrc,.tmux.conf} /root/
|
ln -s $SCRIPTPATH/{vim/.vimrc,tmux/.tmux.conf} /root/
|
||||||
ln -s $SCRIPTPATH/vim/colors /root/.vim/
|
ln -s $SCRIPTPATH/vim/colors /root/.vim/
|
||||||
echo 'Linking configuration files done'
|
echo 'Linking configuration files done'
|
||||||
else
|
else
|
||||||
|
|
@ -48,4 +30,3 @@ function user_config {
|
||||||
}
|
}
|
||||||
|
|
||||||
user_config
|
user_config
|
||||||
echo 'Dont forget to run :PlugInstall inside vim!'
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue