Created
November 2, 2021 12:58
-
-
Save denis2glez/24e163770a1cf0908836778b86c59758 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [[ $EUID -ne 0 ]]; then | |
echo "This script must be run as root!" | |
exit 1 | |
fi | |
# Synchronizes the repository databases and updates the system's packages, excluding "local" | |
# packages | |
sudo pacman -Syu | |
# Group with basic tools required to build many packages (e.g. when installing an AUR package) | |
sudo pacman -S --needed base-devel | |
# To remove all files from the cache, use the clean switch twice, this will leave nothing in the | |
# cache folder | |
sudo pacman -Sc | |
# See the first items in `arch_tweaks.md` (https://gist.github.com/denis2glez/25f38c006f666c51b4d07ee64b01cd43) | |
# for more details. | |
# | |
# To install packages from a previously saved list of packages, while not reinstalling previously | |
# installed packages that are already up-to-date, run | |
sudo pacman -S --needed - </mnt/pkg/pkg_list.txt | |
# Optionally install an AUR helper. | |
# For instance, `yay`(https://github.com/Jguer/yay) is an AUR | |
# helper written in Go. | |
git clone https://aur.archlinux.org/yay.git | |
cd yay | |
makepkg -si | |
# See the first items in `arch_tweaks.md` (https://gist.github.com/denis2glez/25f38c006f666c51b4d07ee64b01cd43) | |
# for more details. | |
# To install AUR packages from a previously saved list | |
yay -S --needed - </mnt/pkg/foreign_pkg_list.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment