Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- #Create all the functions to make calling things easier later on.
- main_menu() #beginning of main menu function
- {
- clear
- while [ 1=1 ]
- do
- echo "[1] - Sync local data with mirror [2] - Sync & Update System"
- echo "[3] - Graphics [4] - Misc Applications"
- echo
- echo -n "Enter choice here: "
- read choice
- if [ "$choice" = "1" ]
- then clear
- echo "Syncing local package information with the mirror..."
- pacman -Sy
- read -n 1 -p "Press any key to continue.."
- clear
- elif [ "$choice" = "2" ]
- then clear
- echo "Syncing package information with mirror and updating packages.."
- pacman -Syu
- read -n 1 -p "Press any key to continue..."
- clear
- elif [ "$choice" = "3" ]
- then clear
- graphics
- elif [ "$choice" = "4" ]
- then clear
- misc_apps
- else
- echo "You done typed the wrong keys buddy"
- fi
- done
- }
- #End of Main Menu Function
- KDE() #Beginning of KDE function
- {
- while [ 1=1 ]
- do
- echo "[I]nstall the group KDE"
- echo "[B]ack to Desktop Environments Menu"
- echo "[R]eturn to main menu"
- echo
- echo -n "Enter choice here"
- read choice
- if [ "$choice" = "i" ]
- then
- clear
- echo "Syncing repositories and downloading KDE4..."
- pacman -Sy kde
- read -n 1 -p "Press any Key to continue..."
- clear
- elif [ "$choice" = "b" ]
- then sleep 1
- clear
- echo "returning to Desktop Environments.."
- clear
- desktop_environments
- elif [ "$choice" = "r" ]
- then clear
- main_menu
- else
- echo "You done typed the wrong key buddy!"
- fi
- done
- }
- #End of KDE function
- GNOME()
- {
- clear
- while [ 1=1 ]
- do
- echo "[I]nstall the group KDE"
- echo "[B]ack to Desktop Environments Menu"
- echo "[R]eturn to main menu"
- echo
- echo -n "Enter choice here"
- read choice
- if [ "$choice" = "i" ]
- then clear
- echo "Syncing repositories and downloading GNOME..."
- pacman -Sy gnome gnome-extra
- read -n 1 -p "Press any key to continue..."
- clear
- elif [ "$choice" = "b" ]
- then clear
- sleep 1
- echo "Returning to Desktop Environments..."
- desktop_environments
- elif [ "$choice" = "r" ]
- then clear
- sleep 1
- echo "Returning to Main Menu.."
- main_menu
- else
- echo "You done type the wrong key buddy!"
- fi
- done
- }
- #TODO
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement