Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 25 additions & 1 deletion .chezmoidata/packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,28 @@ fedora:
- "com.slack.Slack"
- "com.spotify.Client"
- "rest.insomnia.Insomnia"
- "com.google.AndroidStudio"
- "com.google.AndroidStudio"
cachyos:
packages:
- "git"
- "zsh"
- "zoxide"
- "fzf"
- "ripgrep"
- "fastfetch"
- "starship"
- "chromium"
- "qemu-desktop"
- "libvirt"
- "edk2-ovmf"
- "dnsmasq"
- "iptables-nft"
aur:
- "ghostty"
- "google-chrome"
- "mise"
- "visual-studio-code-bin"
- "slack-desktop"
- "spotify"
- "insomnia"
- "android-studio"
42 changes: 42 additions & 0 deletions .chezmoiscripts/run_onchange_install-packages-cachyos.sh.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#!/bin/bash

set -euo pipefail

# Functie om te controleren of een commando bestaat
command_exists() {
command -v "$1" >/dev/null 2>&1
}

# Installeer yay indien niet aanwezig
if ! command_exists yay; then
echo "yay niet gevonden. Bezig met installeren van yay..."
sudo pacman -S --needed --noconfirm git base-devel
git clone https://aur.archlinux.org/yay.git /tmp/yay
(cd /tmp/yay && makepkg -si --noconfirm)
rm -rf /tmp/yay
fi

# Installeer pakketten uit de officiële repositories
{{- if .packages.cachyos.packages }}
echo "Bezig met installeren van pakketten uit de officiële repositories..."
yay -S --needed --noconfirm {{ .packages.cachyos.packages | join " " }}
{{- end }}

# Installeer AUR-pakketten
{{- if .packages.cachyos.aur }}
echo "Bezig met installeren van AUR-pakketten..."
yay -S --needed --noconfirm {{ .packages.cachyos.aur | join " " }}
{{- end }}

# Post-installatie configuratie voor virtualisatie
{{- if has "libvirt" .packages.cachyos.packages }}
echo "Bezig met configureren van virtualisatie..."
echo "Voeg gebruiker toe aan de libvirt groep..."
sudo usermod -a -G libvirt $(whoami)

echo "Inschakelen en starten van de libvirtd service..."
sudo systemctl enable libvirtd.service
sudo systemctl start libvirtd.service
{{- end }}

echo "CachyOS pakketinstallatie voltooid."
2 changes: 2 additions & 0 deletions run_onchange_install-packages.sh.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,7 @@ set -euo pipefail
# Debian-specific code
{{ else if eq .chezmoi.osRelease.id "fedora" }}
{{ includeTemplate ".chezmoiscripts/run_onchange_install-packages-fedora.sh.tmpl" . }}
{{ else if eq .chezmoi.osRelease.id "cachyos" }}
{{ includeTemplate ".chezmoiscripts/run_onchange_install-packages-cachyos.sh.tmpl" . }}
{{ end }}
{{ end }}