diff --git a/install.sh b/install.sh index e2acf7a..4c7b9be 100755 --- a/install.sh +++ b/install.sh @@ -111,7 +111,7 @@ echo -e " \e[34m- build-essential \e[1;31mSelect option 1 \e[91m Missing pa echo -e "\n YOU CAN SKIP (auto) install if you want" echo -e "\n\e[92m Please Select:" echo -e " 1. \e[0m(auto) Install Missing Package\e[92m" -echo -e " 2. \e[0mInstallation MOTDs32 script\e[92m" +echo -e " 2. \e[0mInstallation/(CHECK) MOTDs32 script\e[92m" echo -e " 3. \e[0mUninstall completly MOTDs32 script\e[92m" echo -e " 0. \e[0m(Enter or any key) to Quit\n \e[0m" read -p " Enter selection [0-3] or (Enter) to Quit > " selection @@ -140,13 +140,13 @@ tput cup 11 0 fi echo -e "\e[92m" - if [ `grep -c /etc/motd /root/.bashrc` == 0 ] + if [ `grep -c /etc/motd ~/.bashrc` == 0 ] then echo -e " \e[1;31m code bash missing" - echo "cat /etc/motd" >> /root/.bashrc + echo "cat /etc/motd" >> ~/.bashrc echo -e "\e[92m - Code bash \e[0madded.\n" else - grepmot=`grep '/etc/motd' /root/.bashrc` + grepmot=`grep '/etc/motd' ~/.bashrc` echo -e " \e[1;30m Code bash found: \e[0m>>\e[0m $grepmot \e[0m<<\n" echo -e " -->\e[34m Code bash: \e[92mOK\e[0m" fi @@ -192,23 +192,23 @@ if test -f /usr/bin/motds32; then /usr/bin/motds32 -g; fi echo -e "\n\n\e[34m \e[92m Installation of MOTDs32 completed!\e[0m \n\n\n Help? Use: \n \033[1;30m /usr/bin/motds32\e[0m \n or \033[1;30m\n motd\e[0m\n" printf "\n \e[1;33m (Press 0 to exit)\e[0m" - printf "\n \e[1;33m (Or any key to go back.)\e[0m" + printf "\n \e[1;33m (Or any key to go back.)\e[0m" ;; 2) echo -e "\n\e[92m" - if [ `grep -c /etc/motd /root/.bashrc` == 0 ] + if [ `grep -c /etc/motd ~/.bashrc` == 0 ] then echo -e " code bash missing" - echo "cat /etc/motd" >> /root/.bashrc + echo "cat /etc/motd" >> ~/.bashrc echo -e "\e[92m - Code bash \e[0madded.\n" else - grepmot=`grep '/etc/motd' /root/.bashrc` + grepmot=`grep '/etc/motd' ~/.bashrc` echo -e " \e[1;30m Code bash found: \e[0m>>\e[0m $grepmot \e[0m<<\n" echo -e " -->\e[34m Code bash: \e[92mOK\e[0m" fi # Check if MOTDs32 is already add if test ! -d /etc/motds32; then mkdir -p /etc/motds32; fi - + if [ -f "/usr/bin/motds32" ] then echo -e "\n\e[34m - Make file \e[0m>> founded.\e[0m\n" @@ -276,14 +276,14 @@ if test -f /usr/bin/motds32; then /usr/bin/motds32 -g; fi echo -e " \e[93m Cron not find\n" fi - if [ `grep -c /etc/motd /root/.bashrc` == 0 ] + if [ `grep -c /etc/motd ~/.bashrc` == 0 ] then echo " Code bash not founded" else echo " code bash founded" - sed -i '/cat \/etc\/motd/d' /root/.bashrc + sed -i '/cat \/etc\/motd/d' ~/.bashrc echo -e "\e[92m Code .bashrc remove.\e[0m" - grep -n '/etc/motd' /root/.bashrc + grep -n '/etc/motd' ~/.bashrc fi echo -e "\n\e[92m Script MOTDs32 has been completly removed \e[0m"