feat(music): add enable option

This commit is contained in:
2026-05-22 10:23:03 +02:00
parent e84079647b
commit a5adea70ea
4 changed files with 15 additions and 7 deletions

View File

@@ -59,6 +59,7 @@
shell.bash.aliases.lang-js = true;
shell.bash.addBinToPath = true;
audio.enable = true;
music.enable = true;
terminal.enable = true;
devenv.enable = true;
keepassxc.enable = true;

View File

@@ -56,6 +56,7 @@
shell.bash.addBinToPath = true;
my.yubikey.enable = true;
audio.enable = true;
music.enable = true;
terminal.enable = true;
devenv.enable = true;
keepassxc.enable = true;

View File

@@ -65,6 +65,7 @@
browser.primary = "firefox";
devenv.enable = true;
music.enable = true;
terminal.enable = true;
keepassxc.enable = true;
direnv.enable = true;

View File

@@ -1,10 +1,13 @@
{
dotsPath,
config,
lib,
pkgs,
dotsPath,
...
}:
let
cfg = config.music;
spotifyWithWayland = pkgs.symlinkJoin {
name = "spotify";
paths = [ pkgs.spotify ];
@@ -16,12 +19,14 @@ let
};
in
{
home.packages = with pkgs; [
spotifyWithWayland
];
options.music.enable = lib.mkEnableOption "music";
config = lib.mkIf cfg.enable {
home.packages = [ spotifyWithWayland ];
programs.ncspot = {
enable = true;
settings = builtins.fromTOML (builtins.readFile (dotsPath + "/.config/ncspot/config.toml"));
settings = fromTOML (builtins.readFile (dotsPath + "/.config/ncspot/config.toml"));
};
};
}