Compare commits

...

2 Commits

6 changed files with 135 additions and 26 deletions

53
flake.lock generated
View File

@@ -347,6 +347,22 @@
} }
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": {
"lastModified": 1768564909,
"narHash": "sha256-Kell/SpJYVkHWMvnhqJz/8DqQg2b6PguxVWOuadbHCc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "e4bae1bd10c9c57b2cf517953ab70060a828ee6f",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1768380750, "lastModified": 1768380750,
"narHash": "sha256-V5drPOmaGA7bszxKxyViYEZyT2h6RYa/Ll+3aJL4Grs=", "narHash": "sha256-V5drPOmaGA7bszxKxyViYEZyT2h6RYa/Ll+3aJL4Grs=",
@@ -414,6 +430,7 @@
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"pumo-system-info": "pumo-system-info", "pumo-system-info": "pumo-system-info",
"sops-nix": "sops-nix", "sops-nix": "sops-nix",
"spicetify": "spicetify",
"srvos": "srvos", "srvos": "srvos",
"zen-browser": "zen-browser" "zen-browser": "zen-browser"
} }
@@ -459,9 +476,28 @@
"type": "github" "type": "github"
} }
}, },
"spicetify": {
"inputs": {
"nixpkgs": "nixpkgs_2",
"systems": "systems_2"
},
"locked": {
"lastModified": 1768656845,
"narHash": "sha256-xNlXMyn7yc3Z/NOsz4NchO7gWFwsoCvtJ26pys4s2/M=",
"owner": "Gerg-L",
"repo": "spicetify-nix",
"rev": "8bd7e49d5ac62756bee6e4b02221fb96bfc3c99a",
"type": "github"
},
"original": {
"owner": "Gerg-L",
"repo": "spicetify-nix",
"type": "github"
}
},
"srvos": { "srvos": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_2" "nixpkgs": "nixpkgs_3"
}, },
"locked": { "locked": {
"lastModified": 1768523683, "lastModified": 1768523683,
@@ -492,6 +528,21 @@
"type": "github" "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"
}
},
"treefmt-nix": { "treefmt-nix": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [

View File

@@ -34,6 +34,8 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
spicetify.url = "github:Gerg-L/spicetify-nix";
srvos.url = "github:nix-community/srvos"; srvos.url = "github:nix-community/srvos";
zen-browser = { zen-browser = {
@@ -91,6 +93,7 @@
pkgs = nixpkgs.legacyPackages.x86_64-linux; pkgs = nixpkgs.legacyPackages.x86_64-linux;
defaultUserModules = [ defaultUserModules = [
inputs.sops-nix.homeManagerModules.sops inputs.sops-nix.homeManagerModules.sops
inputs.spicetify.homeManagerModules.default
]; ];
withUserModules = modules: nixpkgs.lib.lists.flatten (defaultUserModules ++ [modules]); withUserModules = modules: nixpkgs.lib.lists.flatten (defaultUserModules ++ [modules]);
in { in {

View File

@@ -15,6 +15,7 @@ in {
./obs.nix ./obs.nix
./qt.nix ./qt.nix
./rofi ./rofi
./spotify.nix
./swaync.nix ./swaync.nix
./waybar.nix ./waybar.nix
./wlr-which-key.nix ./wlr-which-key.nix
@@ -30,6 +31,8 @@ in {
obs.enable = mkDefault cfg.fullDesktop; obs.enable = mkDefault cfg.fullDesktop;
qt.enable = mkDefault cfg.fullDesktop; qt.enable = mkDefault cfg.fullDesktop;
rofi.enable = mkDefault cfg.fullDesktop; rofi.enable = mkDefault cfg.fullDesktop;
spotify.enable = mkDefault cfg.fullDesktop;
spotify.spicetify.enable = mkDefault cfg.fullDesktop;
wlr-which-key.enable = mkDefault cfg.fullDesktop; wlr-which-key.enable = mkDefault cfg.fullDesktop;
}; };
} }

View File

@@ -0,0 +1,25 @@
{
pkgs,
config,
lib,
inputs,
...
}:
with lib; let
cfg = config.home.desktop.spotify;
system = pkgs.stdenv.hostPlatform.system;
spicePkgs = inputs.spicetify.legacyPackages.${system};
in {
options.home.desktop.spotify = {
enable = mkEnableOption "Enable Spotify";
spicetify.enable = mkEnableOption "Enable Spicetify";
};
config.programs = mkIf cfg.enable {
spotify-player.enable = cfg.enable;
spicetify = mkIf cfg.spicetify.enable {
inherit (cfg.spicetify) enable;
theme = spicePkgs.themes.sleek;
colorScheme = "Nord";
};
};
}

View File

@@ -19,7 +19,34 @@ in {
inherit (cfg) enable; inherit (cfg) enable;
enableTransience = true; enableTransience = true;
settings = mkIf cfg.jjIntegration { settings = mkIf cfg.jjIntegration {
custom.jj = { # Disabling these so they can be enabled conditionally
# See https://github.com/jj-vcs/jj/wiki/Starship
git_status.disabled = true;
git_commit.disabled = true;
git_metrics.disabled = true;
git_branch.disabled = true;
custom = let
when = "! jj --ignore-working-copy-root";
description = "Only show if were not in a jj repository";
style = "";
in {
git_status = {
inherit when description style;
command = "starship module git_status";
};
git_commit = {
inherit when description style;
command = "starship module git_commit";
};
git_metrics = {
inherit when description style;
command = "starship module git_metrics";
};
git_branch = {
inherit when description style;
command = "starship module git_branch";
};
jj = {
description = "The current jj status"; description = "The current jj status";
detect_folders = [".jj"]; detect_folders = [".jj"];
symbol = "🥋 "; symbol = "🥋 ";
@@ -46,4 +73,5 @@ in {
}; };
}; };
}; };
};
} }

View File

@@ -30,7 +30,6 @@ in {
plexamp plexamp
plex-desktop plex-desktop
spicetify-cli spicetify-cli
spotify
pavucontrol # Volume control pavucontrol # Volume control
# Social # Social