2024-05-23 20:26:30 +00:00
|
|
|
{
|
|
|
|
|
options,
|
|
|
|
|
config,
|
|
|
|
|
lib,
|
2024-05-23 20:48:19 +00:00
|
|
|
inputs,
|
|
|
|
|
system,
|
2024-05-28 14:45:39 -04:00
|
|
|
pkgs,
|
2024-05-23 20:26:30 +00:00
|
|
|
...
|
|
|
|
|
}:
|
|
|
|
|
with lib;
|
|
|
|
|
with lib.custom; let
|
2024-05-23 20:48:19 +00:00
|
|
|
cfg = config.apps.music.spotify;
|
2024-07-27 00:21:12 -04:00
|
|
|
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system};
|
2024-05-23 20:26:30 +00:00
|
|
|
in {
|
|
|
|
|
options.apps.music.spotify = with types; {
|
|
|
|
|
enable = mkBoolOpt false "Enable Spotify";
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
|
programs.spicetify = {
|
|
|
|
|
enable = true;
|
|
|
|
|
theme = spicePkgs.themes.catppuccin;
|
2024-07-26 14:19:24 -04:00
|
|
|
spotifyPackage = pkgs.spotify.overrideAttrs {
|
|
|
|
|
fixupPhase = ''
|
|
|
|
|
runHook preFixup
|
|
|
|
|
|
|
|
|
|
wrapProgramShell $out/share/spotify/spotify \
|
|
|
|
|
''${gappsWrapperArgs[@]} \
|
|
|
|
|
--prefix LD_LIBRARY_PATH : "$librarypath" \
|
|
|
|
|
--prefix PATH : "${pkgs.gnome.zenity}/bin" \
|
|
|
|
|
--add-flags "--disable-gpu"
|
|
|
|
|
|
|
|
|
|
runHook postFixup
|
|
|
|
|
'';
|
|
|
|
|
};
|
2024-05-23 20:26:30 +00:00
|
|
|
colorScheme = "mocha";
|
|
|
|
|
|
|
|
|
|
enabledExtensions = with spicePkgs.extensions; [
|
|
|
|
|
fullAppDisplay
|
|
|
|
|
shuffle # shuffle+ (special characters are sanitized out of ext names)
|
|
|
|
|
hidePodcasts
|
|
|
|
|
];
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|