System Gen84 @ 2025-07-24-02:00:39 by jonas@monolith

This commit is contained in:
2025-07-24 02:00:40 +02:00
parent 234a70cd78
commit b31e767134
15 changed files with 209 additions and 1 deletions

View File

@@ -0,0 +1,28 @@
{
config,
lib,
pkgs,
...
}: let
cfg = config.hive.programs.spotify-shortcuts;
in {
options.hive.programs.spotify-shortcuts = {
enable = lib.mkEnableOption "Enable Spotify Shortcuts";
clientIdFile = lib.mkOption {
type = lib.types.path;
description = "Spotify API Client ID Path";
};
clientSecretFile = lib.mkOption {
type = lib.types.path;
description = "Spotify API Client Secret Path";
};
};
config = lib.mkIf cfg.enable {
environment.systemPackages = [pkgs.hive.spotify-shortcuts];
environment.etc."profile.d/spotify-shortcuts.sh".text = ''
export SPOTIFY_SHORTCUTS_CLIENT_ID=$(cat ${cfg.clientIdFile})
export SPOTIFY_SHORTCUTS_CLIENT_SECRET=$(cat ${cfg.clientSecretFile})
'';
};
}