Reduce removals list to only things that cannot be unchecked during installation

This commit is contained in:
2025-09-28 03:15:43 -04:00
parent 93fe7a13bd
commit a986d9b17e
4 changed files with 33 additions and 22 deletions
+3 -13
View File
@@ -10,32 +10,22 @@ import (
func removals() {
for {
var doAll bool
choice := front.InputMenuGen("Application to remove:", []string{"back", "all", "alacritty", "pavucontrol", "bash", "linux-cachyos-lts", "ufw", "modemmanager"})
choice := front.InputMenuGen("Application to remove:", []string{"back", "all", "bash", "linux-cachyos-lts"})
var target string
switch choice {
case 1:
return
case 2:
cmd := exec.Command("pacman", "-Rcns", "back", "alacritty", "pavucontrol", "bash", "linux-cachyos-lts", "ufw", "modemmanager", "--noconfirm")
cmd := exec.Command("pacman", "-Rcns", "bash", "linux-cachyos-lts", "--noconfirm")
err := cmd.Run()
if err != nil {
other.PrintError("Failed to perform application removals", 1)
}
doAll = true
case 3:
target = "alacritty"
case 4:
target = "pavucontrol"
case 5:
target = "bash"
case 6:
case 4:
target = "linux-cachyos-lts"
case 7:
target = "ufw"
manageService("stop", "ufw.service")
manageService("disable", "ufw.service")
case 8:
target = "modemmanager"
}
if !doAll {
managePackage("-Rcns", target)