PortValhalla/scripts/Arch/Scripts/deploy.fish

299 lines
7.8 KiB
Fish
Raw Normal View History

function deploySoftware -d "Deploys a the specified software action" -a action
set -l dir (status dirname)
. "$dir/software.fish"
if [ -z "$action" ]
2024-10-06 19:25:34 +00:00
set action install
end
set -l isInstall (
if [ "$action" = "install" ]
echo true
else
echo false
end
)
2024-09-22 15:50:05 +00:00
if isOSEnabled secureBoot
2024-09-19 22:56:56 +00:00
source "$dir/../Config/SecureBoot/main.fish" $argv
end
2024-09-22 15:50:05 +00:00
and if isOSEnabled hardware.surfaceBook
2024-09-20 00:01:22 +00:00
source "$dir/../Drivers/SurfaceBook2/main.fish" $argv
end
2024-09-22 15:50:05 +00:00
and if isOSEnabled hardware.nvidiaGPU
2024-09-20 00:01:22 +00:00
source "$dir/../Software/nvidia-dkms/main.fish" $argv
end
2024-09-22 15:50:05 +00:00
and if isOSEnabled hardware.xoneReceiver
2024-09-20 00:01:22 +00:00
source "$dir/../Software/xone/main.fish" $argv
end
2024-09-22 15:50:05 +00:00
and for component in (getOSConfig hardware.components --json | jq '.[]' --raw-output0 | string split0)
2024-09-30 19:47:52 +00:00
switch "$component"
case "Logitech G903"
source "$dir/../../Common/Drivers/Logitech G903/main.fish" $argv
case "ROG Zenith Extreme Alpha"
if $isInstall
sudo systemctl mask "dev-tpmrm0.device"
end
2024-09-20 04:10:53 +00:00
end
end
and if isEnabled valhalla.windows.dualboot.enable && $isInstall
yayinst bt-dualboot
end
2024-10-13 23:55:19 +00:00
and if collectionActive essential && $isInstall
yayinst \
mkinitcpio-firmware \
neofetch \
bash-completion \
wget \
screen \
tmux \
htop \
lsof \
zsh \
fish \
pkgfile \
sl \
rar
and sudo pkgfile --update
2024-10-13 23:55:19 +00:00
yayinst \
tldr \
btop \
terminal-parrot
end
2024-10-13 23:55:19 +00:00
and source "$dir/../../Common/Software/bash/main.fish" $argv
and source "$dir/../../Common/Software/nuke-usb/main.fish" $argv
and source "$dir/../Software/sudo/main.fish" $argv
and source "$dir/../Software/aliae/main.fish" $argv
and source "$dir/../Software/oh-my-posh/main.fish" $argv
and source "$dir/../Software/openssh/main.fish" $argv
and source "$dir/../Software/vim/main.fish" $argv
and source "$dir/../Software/git/main.fish" $argv
and source "$dir/../Software/zoxide/main.fish" $argv
and source "$dir/../Software/logo-ls/main.fish" $argv
# GRUB Shenanigans - if that's not essential I don't know what is!
and source "$dir/../Software/minegrub-theme/main.fish" $argv
# Desktop Experience
2024-10-25 10:53:05 +00:00
and source "$dir/../Software/plasma/main.fish" $argv
2024-10-13 23:55:19 +00:00
and source "$dir/../Software/sddm/main.fish" $argv
and source "$dir/../Software/icedtea/main.fish" $argv
and if collectionActive desktopExperience && $isInstall
yayinst \
maliit-keyboard \
dconf-editor \
flatpak (
# Fixes: https://www.reddit.com/r/flatpak/comments/168tav2/how_to_fix_blurry_flatpaks_on_high_resolution/
) xdg-desktop-portal-gtk
# Fonts
and yayinst \
ttf-cascadia-code-nerd \
ttf-ms-win11-auto \
otf-cascadia-code \
ttf-droid
# Password Management
and yayinst \
bitwarden \
keepass \
keepassxc
# Tools
and yayinst \
android-tools \
blackbox-terminal \
cpu-x \
gnome-calculator \
yubikey-manager-qt \
wireshark-qt \
linux-wifi-hotspot
# Remote Access
and yayinst \
remmina (
# RDP support for Remmina
) freerdp
# Creativity
and yayinst \
gimp \
inkscape
# Office stuff
and yayinst \
libreoffice-fresh \
naps2-bin \
pdfarranger \
protonmail-bridge
and yayinst \
texlive \
texlive-langgerman
# Virtualization
2024-10-13 23:55:19 +00:00
and yayinst propertree-git # mac .plist config file editor
end
2024-10-13 23:55:19 +00:00
and if isProgramEnabled "thunderbird" && $isInstall
yayinst thunderbird
end
2024-10-13 23:55:19 +00:00
# School & Studies
and if collectionActive school && $isInstall
yayinst \
teams-for-linux \
xournalpp-git \
rnote
end
2024-10-13 23:55:19 +00:00
# Internet Access
and source "$dir/../Software/firefox/main.fish" $argv
and source "$dir/../Software/brave/main.fish" $argv
and source "$dir/../Software/pennywise/main.fish" $argv
# Virtualization
and source "$dir/../Software/waydroid/main.fish" $argv
and source "$dir/../Software/virt-manager/main.fish" $argv
and if $isInstall
if collectionActive server
else
# Energy Saving
yayinst power-profiles-daemon
2024-09-13 13:10:29 +00:00
and sudo systemctl enable --now power-profiles-daemon
# Networking
2024-09-13 13:10:29 +00:00
and yayinst \
networkmanager-openvpn \
networkmanager-openconnect \
2024-09-13 12:53:46 +00:00
proton-vpn-gtk-app \
2024-10-21 23:18:31 +00:00
protonvpn-cli-community \
img2pdf \
numbat-bin \
nvtop \
pdf2svg \
tnef
end
2024-10-13 23:55:19 +00:00
and if collectionActive media
yayinst \
ytmdesktop-bin \
netflix \
spotube-bin \
stremio \
tidal-dl-ng \
tidal-hifi-bin \
nuclear-player-bin \
audius-client-bin
end
2024-10-13 23:55:19 +00:00
and if isProgramEnabled "nextcloud"
yayinst nextcloud-client
end
end
2024-10-13 23:55:19 +00:00
and source "$dir/../Software/rclone/main.fish" $argv
2024-09-13 12:55:50 +00:00
2024-10-13 23:55:19 +00:00
if $isInstall
if collectionActive socialMedia
yayinst signal-desktop
and begin
yes y | runYay threema-desktop
end
and begin
yes y | runYay nodejs
end
2024-09-13 14:32:39 +00:00
end
2024-10-13 23:55:19 +00:00
and if isProgramEnabled discord
yayinst vesktop-bin
2024-09-13 14:32:39 +00:00
end
2024-10-13 23:55:19 +00:00
and if collectionActive productivity
yayinst \
anki-bin
end
end
2024-10-13 23:55:19 +00:00
and if collectionActive school
if $isInstall
yayinst \
jdk17-temurin \
gradle \
jetbrains-toolbox
end
2024-09-13 13:10:29 +00:00
and source "$dir/../../Common/Software/udev/ct-board.fish"
end
2024-10-13 23:55:19 +00:00
# Development
2024-09-13 13:10:29 +00:00
and if collectionActive coding
if $isInstall
yayinst \
archiso \
wimlib (
# ISO support for wimlib
) cdrkit \
tea \
woodpecker-cli (
# AsciiDocs
) python-docutils (
# reStructuredText
2024-10-13 23:55:19 +00:00
) esbonio \
devdocs-desktop \
godot-mono \
python \
python-pip \
python-pipenv
end
end
2024-10-13 23:55:19 +00:00
and source "$dir/../Software/pyenv/main.fish" $argv
and source "$dir/../Software/nodejs-n/main.fish" $argv
and source "$dir/../Software/docker/main.fish" $argv
and source "$dir/../Software/vscode/main.fish" $argv
2024-10-13 23:55:19 +00:00
if $isInstall
if collectionActive gaming
if $isInstall
yayinst \
supertux \
gamepad-tool-bin
and yayinst chiaki-ng || true
2024-10-13 23:55:19 +00:00
and sudo flatpak install -y flathub com.usebottles.bottles
end
end
and if isProgramEnabled "osu!lazer"
yayinst osu-lazer-bin
end
2024-10-13 23:55:19 +00:00
and if isProgramEnabled "retroarch"
yayinst libretro
end
end
2024-10-13 23:55:19 +00:00
and source "$dir/../Software/lutris/main.fish" $argv
and source "$dir/../Software/steam/main.fish" $argv
2024-09-13 13:10:29 +00:00
and if collectionActive essential && $isInstall
yayinst bb
end
end
deploySoftware $argv