├── Install_All.sh └── README.md /Install_All.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Function to install selected NVIDIA driver 4 | install_nvidia_driver() { 5 | echo "Select the NVIDIA driver to install:" 6 | echo "1. nvidia-dkms" 7 | echo "2. nvidia-open-dkms" 8 | echo "3. nvidia-lts" 9 | echo "4. None" 10 | read -p "Enter the number of your choice: " choice 11 | 12 | case $choice in 13 | 1) 14 | if ! pacman -Qs nvidia-dkms > /dev/null; then 15 | echo "Installing nvidia-dkms..." 16 | sudo pacman -S nvidia-dkms --noconfirm 17 | else 18 | echo "nvidia-dkms is already installed." 19 | fi 20 | ;; 21 | 2) 22 | if ! pacman -Qs nvidia-open-dkms > /dev/null; then 23 | echo "Installing nvidia-open-dkms..." 24 | sudo pacman -S nvidia-open-dkms --noconfirm 25 | else 26 | echo "nvidia-open-dkms is already installed." 27 | fi 28 | ;; 29 | 3) 30 | if ! pacman -Qs nvidia-lts > /dev/null; then 31 | echo "Installing nvidia-lts..." 32 | sudo pacman -S nvidia-lts --noconfirm 33 | else 34 | echo "nvidia-lts is already installed." 35 | fi 36 | ;; 37 | 4) 38 | echo "No NVIDIA driver will be installed." 39 | ;; 40 | *) 41 | echo "Invalid choice. No NVIDIA driver will be installed." 42 | ;; 43 | esac 44 | } 45 | 46 | # Update the system 47 | echo "Updating system..." 48 | sudo pacman -Syu --noconfirm 49 | 50 | # Install the selected NVIDIA driver 51 | install_nvidia_driver 52 | 53 | # Function to install a package if not already installed 54 | install_if_not_installed() { 55 | if ! pacman -Qs $1 > /dev/null; then 56 | echo "Do you want to install $1? (y/n)" 57 | read choice 58 | if [[ $choice == "y" ]]; then 59 | echo "Installing $1..." 60 | sudo pacman -S $1 --noconfirm 61 | else 62 | echo "Skipping $1 installation." 63 | fi 64 | else 65 | echo "$1 is already installed." 66 | fi 67 | } 68 | 69 | # Install various software packages that are very major 70 | software_list=( 71 | "visual-studio-code-bin" 72 | "microsoft-edge-stable-bin" 73 | "brave" 74 | "google-chrome" 75 | "spotify" 76 | "discord" 77 | "vlc" 78 | "gimp" 79 | "libreoffice-fresh" 80 | "nodejs" 81 | "npm" 82 | "docker" 83 | "python" 84 | "python-pip" 85 | "mongodb" 86 | "gnupg" 87 | "zoom" 88 | "telegram-desktop" 89 | "mongodb-compass" 90 | "postman" 91 | "htop" 92 | "thunderbird" 93 | "slack-desktop" 94 | "anydesk" 95 | "gnupg" 96 | "coreimage" 97 | ) 98 | 99 | for software in "${software_list[@]}"; do 100 | install_if_not_installed $software 101 | done 102 | 103 | # Additional Developer Tools 104 | developer_tools_list=( 105 | "git" 106 | "yarn" 107 | "neovim" 108 | "intellij-idea-community-edition" 109 | "jetbrains-toolbox" 110 | "rust" 111 | "go" 112 | "php" 113 | "mysql" 114 | "postgresql" 115 | "dbeaver" 116 | ) 117 | 118 | for tool in "${developer_tools_list[@]}"; do 119 | install_if_not_installed $tool 120 | done 121 | 122 | # System Monitoring Tools 123 | monitoring_tools_list=( 124 | "bpytop" 125 | "glances" 126 | "iotop" 127 | "iftop" 128 | "lm_sensors" 129 | ) 130 | 131 | for tool in "${monitoring_tools_list[@]}"; do 132 | install_if_not_installed $tool 133 | done 134 | 135 | # System Utilities 136 | system_utilities_list=( 137 | "flameshot" 138 | "timeshift" 139 | "gparted" 140 | "obs-studio" 141 | "bleachbit" 142 | "stacer" 143 | ) 144 | 145 | for utility in "${system_utilities_list[@]}"; do 146 | install_if_not_installed $utility 147 | done 148 | 149 | 150 | # Process Monitoring Tools 151 | process_monitoring=( 152 | "htop" # Interactive process viewer 153 | "btop" # Resource monitor with mouse support 154 | "atop" # Advanced system monitor 155 | "bashtop" # Resource monitor written in bash 156 | "bpytop" # Python resource monitor 157 | "glances" # Cross-platform monitoring tool 158 | ) 159 | 160 | # Network Monitoring Tools 161 | network_monitoring=( 162 | "iftop" # Network bandwidth monitor 163 | "nethogs" # Per-process network bandwidth monitor 164 | "bandwhich" # Network utilization tool 165 | "nload" # Real-time network traffic monitor 166 | "iptraf-ng" # Interactive network monitor 167 | "goaccess" # Real-time web log analyzer 168 | ) 169 | 170 | # Disk/IO Monitoring Tools 171 | disk_monitoring=( 172 | "iotop" # I/O monitoring per process 173 | "ioping" # I/O latency monitoring tool 174 | "ftop" # File system monitor 175 | "fatrace" # File access tracer 176 | "dstat" # Versatile disk stats tool 177 | ) 178 | 179 | # Hardware Sensors Tools 180 | hardware_monitoring=( 181 | "lm_sensors" # Hardware sensor information 182 | "psensor" # Hardware temperature monitoring 183 | "s-tui" # CPU monitoring and stress testing 184 | "nvtop" # NVIDIA GPU process monitoring 185 | "powertop" # Power consumption monitor 186 | ) 187 | 188 | # Complete System Monitoring Tools 189 | system_monitoring=( 190 | "netdata" # Real-time performance monitoring 191 | "prometheus" # Monitoring system & time series database 192 | "grafana" # Analytics and monitoring solution 193 | "zabbix-agent" # Enterprise monitoring solution 194 | "telegraf" # Server monitoring agent 195 | "monit" # System monitoring and error recovery 196 | ) 197 | 198 | # Performance Analysis Tools 199 | performance_tools=( 200 | "perf" # Performance analysis tools 201 | "sysstat" # System performance tools collection 202 | "collectl" # Performance data collector 203 | "sar" # System activity reporter 204 | "strace" # System call tracer 205 | "latencytop" # System latency monitoring 206 | ) 207 | 208 | # Memory Monitoring Tools 209 | memory_monitoring=( 210 | "vmstat" # Virtual memory statistics 211 | "slabtop" # Kernel slab cache information 212 | "smem" # Memory reporting tool 213 | ) 214 | 215 | # Desktop Monitoring Tools 216 | desktop_monitoring=( 217 | "conky" # Desktop system monitor 218 | "stacer" # System optimizer and monitor 219 | "gotop" # Terminal based graphical monitor 220 | "bottom" # Rust-based system monitor 221 | ) 222 | 223 | # System Information Tools 224 | system_info=( 225 | "inxi" # System information script 226 | "neofetch" # System information tool 227 | "screenfetch" # System information tool 228 | ) 229 | 230 | # Install monitoring tools from each category 231 | echo "Installing Process Monitoring Tools..." 232 | for tool in "${process_monitoring[@]}"; do 233 | install_if_not_installed $tool 234 | done 235 | 236 | echo "Installing Network Monitoring Tools..." 237 | for tool in "${network_monitoring[@]}"; do 238 | install_if_not_installed $tool 239 | done 240 | 241 | echo "Installing Disk/IO Monitoring Tools..." 242 | for tool in "${disk_monitoring[@]}"; do 243 | install_if_not_installed $tool 244 | done 245 | 246 | echo "Installing Hardware Sensors Tools..." 247 | for tool in "${hardware_monitoring[@]}"; do 248 | install_if_not_installed $tool 249 | done 250 | 251 | echo "Installing Complete System Monitoring Tools..." 252 | for tool in "${system_monitoring[@]}"; do 253 | install_if_not_installed $tool 254 | done 255 | 256 | echo "Installing Performance Analysis Tools..." 257 | for tool in "${performance_tools[@]}"; do 258 | install_if_not_installed $tool 259 | done 260 | 261 | echo "Installing Memory Monitoring Tools..." 262 | for tool in "${memory_monitoring[@]}"; do 263 | install_if_not_installed $tool 264 | done 265 | 266 | echo "Installing Desktop Monitoring Tools..." 267 | for tool in "${desktop_monitoring[@]}"; do 268 | install_if_not_installed $tool 269 | done 270 | 271 | echo "Installing System Information Tools..." 272 | for tool in "${system_info[@]}"; do 273 | install_if_not_installed $tool 274 | done 275 | 276 | # Check and start MongoDB service if not already started 277 | echo "Checking MongoDB service status..." 278 | if ! systemctl is-active --quiet mongodb; then 279 | echo "Starting MongoDB service..." 280 | sudo systemctl start mongodb 281 | else 282 | echo "MongoDB service is already running." 283 | fi 284 | 285 | # Check and enable MongoDB service if not already enabled 286 | echo "Checking MongoDB service enablement status..." 287 | if ! systemctl is-enabled --quiet mongodb; then 288 | echo "Enabling MongoDB service..." 289 | sudo systemctl enable mongodb 290 | else 291 | echo "MongoDB service is already enabled." 292 | fi 293 | 294 | echo "Installation complete (Script by Nasir Ali)!" 295 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Automated Software Installation Script 2 | 3 | This script automates the installation of various software packages, developer tools, and monitoring utilities on an Arch-based Linux system using `pacman`. It provides options to install different NVIDIA drivers and other essential tools for development and system monitoring. 4 | 5 | ## Table of Contents 6 | 7 | - [Prerequisites](#prerequisites) 8 | - [How to Clone the Repository](#how-to-clone-the-repository) 9 | - [How to Run the Script](#how-to-run-the-script) 10 | - [What the Script Does](#what-the-script-does) 11 | - [Customization](#customization) 12 | - [Contribution](#contribution) 13 | - [Author](#author) 14 | 15 | ## Prerequisites 16 | 17 | - An Arch Linux or Arch-based distribution installed. 18 | - `git` should be installed on your system. If not, install it using: 19 | 20 | ```bash 21 | sudo pacman -S git --noconfirm 22 | ``` 23 | 24 | ## How to Clone the Repository 25 | 26 | - Open your terminal. 27 | - Navigate to the directory where you want to clone the repository. 28 | - Clone the repository using the following command. 29 | 30 | ```bash 31 | git clone https://github.com/Nasir-buddy/Arch_Linux_Bash_Script.git 32 | ``` 33 | 34 | - Navigate into the cloned repository: 35 | 36 | ```bash 37 | cd Arch_Linux_Bash_Script 38 | ``` 39 | 40 | ## How to Run the Script 41 | 42 | - Make the script executable: 43 | 44 | ```bash 45 | chmod +x Install_All.sh 46 | ``` 47 | 48 | - Run the script: 49 | 50 | ```bash 51 | ./Install_All.sh 52 | ``` 53 | 54 | ## What the Script Does 55 | 56 | - **NVIDIA Driver Selection**: You'll be prompted to select an NVIDIA driver to install. 57 | - **Software Installation**: For each software package, you'll be asked if you want to install it. 58 | - **MongoDB Service**: The script will check and start the MongoDB service if it's not already running. 59 | - **Software Packages**: Installs a list of various software packages if they are not already installed. 60 | - **Developer Tools**: Installs additional developer tools for programming and development. 61 | - **System Monitoring Tools**: Installs various monitoring tools categorized into: 62 | - Process Monitoring Tools 63 | - Network Monitoring Tools 64 | - Disk/IO Monitoring Tools 65 | - Hardware Sensors Tools 66 | - Complete System Monitoring Tools 67 | - Performance Analysis Tools 68 | - Memory Monitoring Tools 69 | - Desktop Monitoring Tools 70 | - System Information Tools 71 | - **System Utilities**: Installs utilities for system optimization and management. 72 | - **MongoDB Service Management**: 73 | - Checks if the MongoDB service is active; starts it if not. 74 | - Checks if the MongoDB service is enabled to start on boot; enables it if not. 75 | 76 | ## Customization 77 | 78 | You can customize the script by adding or removing packages from the arrays defined in the script: 79 | 80 | - **Software Packages**: Modify the `software_list` array. 81 | - **Developer Tools**: Modify the `developer_tools_list` array. 82 | - **Monitoring Tools**: Modify the various monitoring tool arrays like `process_monitoring`, `network_monitoring`, etc. 83 | - **System Utilities**: Modify the `system_utilities_list` array. 84 | 85 | ## Contribution 86 | 87 | Contributions are welcome! To contribute to this repository, follow these steps: 88 | 89 | 1. **Fork the Repository**: Click the "Fork" button at the top right of this page to create a copy of this repository in your GitHub account. 90 | 2. **Clone Your Fork**: Clone your forked repository to your local machine using the following command: 91 | 92 | ```bash 93 | git clone https://github.com//Arch_Linux_Bash_Script.git 94 | ``` 95 | 96 | 3. **Create a New Branch**: Create a new branch for your changes: 97 | 98 | ```bash 99 | cd Arch_Linux_Bash_Script 100 | ``` 101 | 102 | 4. **Make Your Changes**: Add or modify the software packages in the script by any code editer or any notepad editer. For example, to add a new monitoring tool, update the relevant array in the `Install_All.sh` script. 103 | 104 | 5. **Update the README**: If you add new software packages or tools, update the README to reflect these changes. Ensure the new software packages are documented under the appropriate sections. 105 | 106 | 6. **Commit Your Changes**: Commit your changes with a meaningful commit message: 107 | 108 | ```bash 109 | git add . 110 | git commit -m "" 111 | ``` 112 | 113 | 7. **Push to Your Fork**: Push your changes to your forked repository: 114 | 115 | ```bash 116 | git push -u origin 117 | ``` 118 | 119 | 8. **Create a Pull Request**: Go to the original repository and create a pull request from your forked repository. Provide a detailed description of your changes and why they should be merged. 120 | 121 | By following these steps, you can contribute to the development of the `Arch_Linux_Bash_Script` project and help improve its functionality. 122 | 123 | ## Author 124 | 125 | **Nasir Ali** 126 | 127 | --------------------------------------------------------------------------------