53 lines
1.8 KiB
Nix
53 lines
1.8 KiB
Nix
{ inputs, self, ... }: {
|
|
flake.nixosModules.graphics = { pkgs, config, lib, ... }: {
|
|
options.features.applications.gui.spotify = {
|
|
enable = lib.mkEnableOption "spotify";
|
|
spicetify.enable = lib.mkEnableOption "spicetify";
|
|
};
|
|
|
|
config = lib.mkIf (config.features.applications.gui.spotify.enable) (inputs.helpers.mkIfElse (config.features.nixos.home-manager.enable) {
|
|
home-manager.users.grey.features.applications.gui.spotify = {
|
|
enable = lib.mkDefault true;
|
|
spicetify.enable = lib.mkDefault config.features.applications.gui.spotify.spicetify.enable;
|
|
};
|
|
} {
|
|
environment.systemPackages = [ pkgs.spotify ];
|
|
});
|
|
};
|
|
|
|
flake.homeModules.graphics = { pkgs, config, lib, ... }: {
|
|
options.features.applications.gui.spotify = {
|
|
enable = lib.mkEnableOption "spotify";
|
|
spicetify.enable = lib.mkEnableOption "spicetify";
|
|
};
|
|
|
|
imports = [
|
|
inputs.spicetify.homeManagerModules.default
|
|
];
|
|
|
|
config = lib.mkIf (config.features.applications.gui.spotify.enable) {
|
|
home.packages = lib.mkIf (!config.features.applications.gui.spotify.spicetify.enable) [ pkgs.spotify ];
|
|
|
|
programs.spicetify =
|
|
let
|
|
spicePkgs = inputs.spicetify.legacyPackages.${pkgs.stdenv.hostPlatform.system};
|
|
in lib.mkIf (config.features.applications.gui.spotify.spicetify.enable) {
|
|
enable = true;
|
|
enabledExtensions = with spicePkgs.extensions; [
|
|
hidePodcasts
|
|
];
|
|
enabledSnippets = with spicePkgs.snippets; [
|
|
spinningCdCoverArt
|
|
oneko
|
|
hideMiniPlayerButton
|
|
hideFullScreenButton
|
|
declutterNowPlayingBar
|
|
modernScrollbar
|
|
];
|
|
enabledCustomApps = with spicePkgs.apps; [
|
|
# marketplace
|
|
];
|
|
};
|
|
};
|
|
};
|
|
} |