Advertisement
v1ral_ITS

ezapt [ sudo apt-get -y install/update/upgrade/purge etc.. ]

Mar 26th, 2018
239
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 4.73 KB | None | 0 0
  1. #!/bin/bash
  2. #######################
  3. # Bash Menu Scripting #
  4. ################################
  5. # GLOBAL VARIABLES IN ALL CAPS #
  6. #########################################################################################
  7. #########################################################################################
  8. ##                                                                                     ##
  9. #  v1ral_ITS   |   ImPerialTeKSolutions@outlook.com   |   www.pastebin.com/u/v1ral_ITS  #
  10. ##                                                                                     ##
  11. #########################################################################################
  12. #########################################################################################
  13. # Console colors
  14. W='\033[0m'  # white (normal)
  15. R='\033[31m'  # red
  16. G='\033[32m'  # green
  17. O='\033[33m'  # orange
  18. B='\033[34m'  # blue
  19. P='\033[35m'  # purple
  20. C='\033[36m'  # cyan
  21. GR='\033[37m'  # gray
  22. BLINK='\e[5m'  # blinking text
  23.  
  24. #####################
  25. # START             #
  26. #####################
  27.  
  28. PS3='Please enter your choice: '
  29. options=("`echo -e $O Update`" "`echo -e $B Upgrade`" "`echo -e $C Install`" "`echo -e $GR Autoremove`" "`echo -e $P Purge`" "`echo -e $W Kill_Processes`" "`echo -e $C Clear Screen`" "`echo -e $GR Enter Your Own Command`" "`echo -e $O List Upgradeable`" "`echo -e $BLINK Quit`")
  30. select opt in "${options[@]}"
  31. do
  32.     case $opt in
  33.         "`echo -e $O Update`")
  34.             sudo apt-get -y update
  35.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  36.             ;;
  37.         "`echo -e $B Upgrade`")
  38.             sudo apt-get -y upgrade
  39.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  40.             ;;
  41.         "`echo -e $C Install`")
  42.             echo -n "What do you want to install?: "
  43.             read INST
  44.             sudo apt-get -y install $INST
  45.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  46.             ;;
  47.         "`echo -e $GR Autoremove`")
  48.             sudo apt-get -y autoremove
  49.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  50.             ;;
  51.         "`echo -e $P Purge`")
  52.             echo -n "What do you want to purge?: "
  53.             read PGE
  54.             sudo apt-get -y purge $PGE
  55.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  56.             ;;
  57.         "`echo -e $W Kill_Processes`")
  58.             echo -e $R"`killps`"
  59.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  60.             ;;
  61.         "`echo -e $C Clear Screen`")
  62.             echo -e $O"`clear`"
  63.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  64.             ;;
  65.         "`echo -e $GR Enter Your Own Command`")
  66.             MSG=$(zenity --title "Terminal Command Entry" --entry )
  67.             sudo $MSG
  68.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  69.             ;;
  70.         "`echo -e $O List Upgradeable`")
  71.             sudo apt list --upgradeable
  72.             echo -e $C"Your options again are, press [E]nter \n `echo $options`"
  73.             ;;
  74.         "`echo -e $BLINK Quit`")
  75.             break
  76.             ;;
  77.         *) echo "invalid option";;
  78.     esac
  79. done
  80. echo -en "Please Email us @ ImPerialTeKSolutions@outlook.com for any and all questions comments, freelance work, and any other projects. We like feedback, thanks!"
  81. sleep 4
  82.  
  83.  
  84. # Console colors ##############
  85. W='\033[0m'  # white (normal) #
  86. R='\033[31m'  # red           #
  87. G='\033[32m'  # green         #
  88. O='\033[33m'  # orange        #
  89. B='\033[34m'  # blue          #
  90. P='\033[35m'  # purple        #
  91. C='\033[36m'  # cyan          #
  92. GR='\033[37m'  # gray         #
  93. BLINK='\e[5m' # blinking text #
  94.                               #
  95.                               #
  96. ###############################
  97. #     REMINDER            #
  98. ###############################
  99.  
  100. cd "`pwd`";
  101.     echo -e \n\n\n`clear`;
  102.     echo -e $GR" `date` ";
  103.     echo -e $O" Shell Scripts Made For You........";
  104.     echo -e $P" Your present working directory is `pwd`...";
  105.     echo -e Inside....
  106.     ls;
  107.     echo -e $W"  
  108.    $R $BLINK########################################################$G##################################################################
  109.     $G $BLINK#####         *                                                                    $R  *                   ####
  110.    $GR $BLINK#####         SHELL SCRIPTS MADE EASY FOR THE LINUX USER      $C    2018_vet   ImP.TeK_Solutions TM                     ####
  111.     $G $BLINK#####         *                                                                        $R  *                   ####
  112.    $R $BLINK########################################################$G##################################################################
  113.    "
  114. date
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement