diff --git a/Scripts/.extra/snap_apps.lst b/Scripts/.extra/snap_apps.lst new file mode 100644 index 0000000..e4dd078 --- /dev/null +++ b/Scripts/.extra/snap_apps.lst @@ -0,0 +1 @@ +btop diff --git a/Scripts/.refind/refind.conf b/Scripts/.refind/refind.conf index b6f50d1..ae60759 100644 --- a/Scripts/.refind/refind.conf +++ b/Scripts/.refind/refind.conf @@ -2,4 +2,6 @@ timeout 3 use_nvram false +dont_scan_files grubx64.efi bootx64.efi + include themes/catppuccin/mocha.conf \ No newline at end of file diff --git a/Scripts/custom_pst.sh b/Scripts/custom_pst.sh index 9fb4123..5b7afc1 100755 --- a/Scripts/custom_pst.sh +++ b/Scripts/custom_pst.sh @@ -1,5 +1,6 @@ #!/usr/bin/env bash +scrDir=$(dirname "$(realpath "$0")") REFINDCONF="/boot/efi/EFI/refind/refind.conf" @@ -29,7 +30,6 @@ install_theme(){ install_snap(){ - echo "Installing dependencies..." echo "Cloning Snapd AUR package..." git clone https://aur.archlinux.org/snapd.git @@ -65,6 +65,41 @@ install_snap(){ echo "Snap installation complete!" +} + +install_snap_apps(){ + # Set the path to the snap_apps.lst file + SNAP_APPS_FILE=".extra/snap_apps.lst" + + # Check if the file exists + if [ ! -f "$SNAP_APPS_FILE" ]; then + echo "File $SNAP_APPS_FILE not found!" + exit 1 + fi + +# Read each line in the "snap_apps.lst" file +while IFS= read -r line +do + # Skip empty lines and lines starting with '#' + if [ -z "$line" ] || [[ "$line" == \#* ]]; then + continue + fi + + # Install the snap package + echo "Installing snap package: $line" + sudo snap install "$line" + + # Check if the installation was successful + if [ $? -eq 0 ]; then + echo "$line installed successfully!" + else + echo "Failed to install $line" + fi +done < "$SNAP_APPS_FILE" + +echo "All snap packages have been processed." + + } # Check with sudo @@ -76,7 +111,16 @@ else install_theme fi -install_snap - +read -p "Do you want to install Snap? (y/n): " answer +# Handle user input +if [[ "$answer" =~ ^[Yy]$ ]]; then + # Install Snapd + install_snapd + + # Install Snap packages + install_snap_apps +else + echo "Snap installation skipped" +fi