PortValhalla/scripts/Arch/OS/install.sh

42 lines
976 B
Bash
Executable file

#!/bin/bash -e
rootDir="${BASH_SOURCE%/*}";
customPortValhallaSudoConfigFile="/etc/sudoers.d/1337_PortValhalla"
pushd "$rootDir" > /dev/null;
. "../../Common/Scripts/hooks.sh";
function autoRoot() {
{
echo "$USER ALL=(ALL:ALL) NOPASSWD: ALL"
} | sudo tee "$customPortValhallaSudoConfigFile" > /dev/null;
}
function defaultProfileSetup() {
NEXTCLOUD_DIR="${NEXTCLOUD_DIR}" \
INSTALL_FONTS=0 \
. "$(pwd)/../../../scripts/Common/Config/UserProfile/install.sh";
}
runHook initialize \
autoRoot;
. "../Software/base-devel/install.sh";
. "../Config/pacman/install.sh";
. "../Software/yay/install.sh";
sudo pacman --noconfirm -Syu pacman-contrib;
runHook installDrivers;
runHook installSoftware \
. "$(pwd)/../Collections/personal.sh";
runHook initializeConfig;
runHook initializeProfile \
defaultProfileSetup;
runHook postInstall \
sudo rm "$customPortValhallaSudoConfigFile" /var/db/sudo/lectured/$UID;
popd > /dev/null;