From 69e17cbf9f63f6e923e2b157a8a1c4f471d0ed94 Mon Sep 17 00:00:00 2001 From: Alexandre Date: Sat, 13 Dec 2025 12:09:52 +0100 Subject: [PATCH] Separated Spotify and Spicetify --- flake.lock | 53 +++++++++++++++++++++++++++++- hosts/nixos/home.nix | 7 ++-- hosts/nixos/modules.nix | 1 + modules/common/spotify.nix | 22 ------------- modules/home-manager/spicetify.nix | 24 ++++++++++++++ 5 files changed, 80 insertions(+), 27 deletions(-) create mode 100644 modules/home-manager/spicetify.nix diff --git a/flake.lock b/flake.lock index 1e8d20d..e047332 100644 --- a/flake.lock +++ b/flake.lock @@ -463,6 +463,22 @@ "type": "github" } }, + "nixpkgs_3": { + "locked": { + "lastModified": 1764950072, + "narHash": "sha256-BmPWzogsG2GsXZtlT+MTcAWeDK5hkbGRZTeZNW42fwA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "f61125a668a320878494449750330ca58b78c557", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, "pre-commit-hooks": { "inputs": { "flake-compat": "flake-compat", @@ -491,7 +507,27 @@ "home-manager": "home-manager", "hyprland": "hyprland", "nix-darwin": "nix-darwin", - "nixpkgs": "nixpkgs_2" + "nixpkgs": "nixpkgs_2", + "spicetify-nix": "spicetify-nix" + } + }, + "spicetify-nix": { + "inputs": { + "nixpkgs": "nixpkgs_3", + "systems": "systems_2" + }, + "locked": { + "lastModified": 1765082296, + "narHash": "sha256-EcefoixU9ht+P6QB/TfjLY9E3MdJVfeSec6G8Ges0pA=", + "owner": "Gerg-L", + "repo": "spicetify-nix", + "rev": "ac4927ea1ec7e7ea3635a1d8b933106a596c4356", + "type": "github" + }, + "original": { + "owner": "Gerg-L", + "repo": "spicetify-nix", + "type": "github" } }, "systems": { @@ -509,6 +545,21 @@ "type": "github" } }, + "systems_2": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, "xdph": { "inputs": { "hyprland-protocols": [ diff --git a/hosts/nixos/home.nix b/hosts/nixos/home.nix index 0b0dd12..170a14c 100644 --- a/hosts/nixos/home.nix +++ b/hosts/nixos/home.nix @@ -6,12 +6,11 @@ home.username = "alex"; home.homeDirectory = "/home/alex"; - import = [ - # Different imports - # Spotify - ../../common/spotify.nix + imports = [ + ../../modules/home-manager/spicetify.nix ]; + # Hyprland wayland.windowManager.hyprland = { enable = true; diff --git a/hosts/nixos/modules.nix b/hosts/nixos/modules.nix index 688b54e..2ccd7f0 100644 --- a/hosts/nixos/modules.nix +++ b/hosts/nixos/modules.nix @@ -6,5 +6,6 @@ ../../modules/nixos/locale.nix # For localisation options ../../modules/nixos/gamming/nvidia.nix # Nvidia (Drivers and Settings) ../../modules/nixos/gamming/steam.nix # For Steam/Proton/Lutris/MangoHUD/Heroic/Bottles + ../../modules/common/spotify.nix # Spotify/Spicetify ]; } diff --git a/modules/common/spotify.nix b/modules/common/spotify.nix index 7e12385..e76cf34 100644 --- a/modules/common/spotify.nix +++ b/modules/common/spotify.nix @@ -11,26 +11,4 @@ # Spotify Connect networking.firewall.allowedUDPPorts = [ 5353 ]; - - # Spicetify - programs.spicetify = - let - spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.hostPlatform.system}; - in - { - enable = true; - - enabledCustomApps = with spicePkgs.apps; [ - newReleases - ncsVisualiser - ]; - - enabledSnippets = with spicePkgs.snippets; [ - rotatingCoverart - pointer - ]; - - theme = spicePkgs.themes.catppuccin; - colorScheme = "mocha"; - } } diff --git a/modules/home-manager/spicetify.nix b/modules/home-manager/spicetify.nix new file mode 100644 index 0000000..973d5f7 --- /dev/null +++ b/modules/home-manager/spicetify.nix @@ -0,0 +1,24 @@ +{ pkgs, inputs, ... }: + + # Spicetify +let + spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.hostPlatform.system}; +in +{ + programs.spicetify = { + enable = true; + + enabledCustomApps = with spicePkgs.apps; [ + newReleases + ncsVisualizer + ]; + + enabledSnippets = with spicePkgs.snippets; [ + rotatingCoverart + pointer + ]; + + theme = spicePkgs.themes.catppuccin; + colorScheme = "mocha"; + }; +}