diff --git a/install b/install index 99bd34c..acbb034 100755 --- a/install +++ b/install @@ -1,7 +1,7 @@ #!/bin/bash #Basic Install Script -echo "This will install to~/.irssi/scripts and create a simlink to autostart the script." +read -p "This will install to~/.irssi/scripts and create a simlink to autostart the script. Press enter to continue or control+c to exit." continue mkdir -p ~/.irssi/scripts/autorun/ -cp sound.pl ~/.irssi/scripts/ -ln -s ~/.irssi/scripts/sound.pl ~/.irssi/scripts/autorun/sound.pl +cp -v sound.pl ~/.irssi/scripts/ +[ -L $HOME/.irssi/scripts/autorun/sound.pl ] || ln -s $HOME/.irssi/scripts/sound.pl $HOME/.irssi/scripts/autorun/sound.pl echo "Done!"