From 977ac07358bd9cbc2e5fa2c3d41e6e50a29d103f Mon Sep 17 00:00:00 2001 From: Frank Zechert Date: Sun, 2 Aug 2026 21:44:40 +0200 Subject: [PATCH] add spotify spicetify themeing --- user/.chezmoidata/packages.yaml | 1 + user/.chezmoiexternal.yaml | 12 ++++++++- ...ange_after_install-spicetify-theme.sh.tmpl | 25 +++++++++++++++++++ ..._onchange_before_install-packages.sh.tmpl} | 0 4 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 user/.chezmoiscripts/run_onchange_after_install-spicetify-theme.sh.tmpl rename user/.chezmoiscripts/{run_onchange_install-packages.sh.tmpl => run_onchange_before_install-packages.sh.tmpl} (100%) diff --git a/user/.chezmoidata/packages.yaml b/user/.chezmoidata/packages.yaml index f1232c3..33d6d40 100644 --- a/user/.chezmoidata/packages.yaml +++ b/user/.chezmoidata/packages.yaml @@ -131,6 +131,7 @@ packages: - slurp - socat - spotify + - spicetify-cli - starship - telegram-desktop - thunderbird diff --git a/user/.chezmoiexternal.yaml b/user/.chezmoiexternal.yaml index 5c1f4a6..2d4a9ae 100644 --- a/user/.chezmoiexternal.yaml +++ b/user/.chezmoiexternal.yaml @@ -1,19 +1,29 @@ +# Configuration for Neovim .config/nvim: type: git-repo url: git@zechert.net:fz-stack/nvim.git - refreshPeriod: 24h + refreshPeriod: 0 +# Theme for Thunderbird .config/thunderbird-theme: type: git-repo url: https://github.com/catppuccin/thunderbird.git refreshPeriod: 168h +# Theme for btop .config/btop/themes/catppuccin_macchiato.theme: type: file url: https://raw.githubusercontent.com/catppuccin/btop/refs/heads/main/themes/catppuccin_macchiato.theme refreshPeriod: 168h +# Theme for DankMateiralShell .config/DankMaterialShell/catppuccin.json: type: file url: https://raw.githubusercontent.com/catppuccin/dankmaterialshell/refs/heads/main/catppuccin.json refreshPeriod: 168h + +# Theme for Spotify / spicetify-cli +.config/spicetify-catppuccin-theme: + type: git-repo + url: https://github.com/catppuccin/spicetify.git + refreshPeriod: 168h diff --git a/user/.chezmoiscripts/run_onchange_after_install-spicetify-theme.sh.tmpl b/user/.chezmoiscripts/run_onchange_after_install-spicetify-theme.sh.tmpl new file mode 100644 index 0000000..46d3d4c --- /dev/null +++ b/user/.chezmoiscripts/run_onchange_after_install-spicetify-theme.sh.tmpl @@ -0,0 +1,25 @@ +#!/usr/bin/bash + +# Install software packages required on the system when the spotify package or theme changes +# spotify hash: {{ include "/opt/spotify/spotify" | sha256sum }} +# catppuccin hash: {{ include "~/.config/spicetify-catppuccin-theme/catppuccin/app.scss" | sha256sum }} + +mkdir -p ~/.config/spicetify/Themes +cp -r ~/.config/spicetify-catppuccin-theme/catppuccin ~/.config/spicetify/Themes/ + +getent group spotify > /dev/null || { + echo "System group spotify is missing" + echo "Please create it with groupadd -r spotify" + echo "Then re-login and try again" + exit 1 +} +sudo chgrp spotify /opt/spotify +sudo chgrp -R spotify /opt/spotify/Apps +sudo chmod 775 /opt/spotify +sudo chmod 775 -R /opt/spotify/Apps + +spicetify backup +spicetify config current_theme catppuccin +spicetify config color_scheme mocha +spicetify config inject_css 1 inject_theme_js 1 replace_colors 1 overwrite_assets 1 +spicetify apply diff --git a/user/.chezmoiscripts/run_onchange_install-packages.sh.tmpl b/user/.chezmoiscripts/run_onchange_before_install-packages.sh.tmpl similarity index 100% rename from user/.chezmoiscripts/run_onchange_install-packages.sh.tmpl rename to user/.chezmoiscripts/run_onchange_before_install-packages.sh.tmpl