diff --git a/modules/home/system/default.nix b/modules/home/system/default.nix index d22b914..b6273cd 100644 --- a/modules/home/system/default.nix +++ b/modules/home/system/default.nix @@ -1,5 +1,6 @@ { imports = [ ./session.nix + ./xdg.nix ]; } diff --git a/snowflake/modules/home/base/xdg/default.nix b/modules/home/system/xdg.nix similarity index 73% rename from snowflake/modules/home/base/xdg/default.nix rename to modules/home/system/xdg.nix index 6a03dc1..7ded06d 100644 --- a/snowflake/modules/home/base/xdg/default.nix +++ b/modules/home/system/xdg.nix @@ -1,42 +1,39 @@ { config, lib, - system, pkgs, ... }: let - inherit (lib.snowfall.system) is-linux; - - inherit (config.marleyos) isDesktop; + inherit (config.marleycfg) profiles; in { config = { home.preferXdgDirectories = true; xdg = let - homeDir = config.home.homeDirectory; + home = config.home.homeDirectory; in lib.mkMerge [ { enable = true; - cacheHome = "${homeDir}/.cache"; - configHome = "${homeDir}/.config"; - dataHome = "${homeDir}/.local/share"; - stateHome = "${homeDir}/.local/state"; + cacheHome = "${home}/.cache"; + configHome = "${home}/.config"; + dataHome = "${home}/.local/share"; + stateHome = "${home}/.local/state"; } - (lib.mkIf (isDesktop && (is-linux system)) { + (lib.mkIf (profiles.desktop && pkgs.stdenv.isLinux) { userDirs = { enable = true; createDirectories = true; - desktop = "${homeDir}/desktop"; + desktop = "${home}/desktop"; documents = null; - download = "${homeDir}/downloads"; + download = "${home}/downloads"; music = null; - pictures = "${homeDir}/pictures"; + pictures = "${home}/pictures"; templates = null; - videos = "${homeDir}/videos"; + videos = "${home}/videos"; }; portal = { @@ -50,7 +47,7 @@ in { enable = true; associations.added = let - browser = "${lib.getName config.marleyos.apps.browser}"; + browser = "${lib.getName config.marleycfg.apps.browser}"; in { "application/json" = ["nvim.desktop"]; "application/pdf" = ["org.pwmt.zathura-pdf-mupdf.desktop"];