diff --git a/configs/flake-parts/home-manager.nix b/configs/flake-parts/home-manager.nix index f5c61be5..3a1fa209 100644 --- a/configs/flake-parts/home-manager.nix +++ b/configs/flake-parts/home-manager.nix @@ -10,6 +10,7 @@ { setups.home-manager = { configs = { + # The typical user in desktop environments. foo-dogsquared = { systems = [ "aarch64-linux" "x86_64-linux" ]; overlays = [ @@ -35,6 +36,7 @@ }; }; + # The typical user in server environments. plover.systems = [ "x86_64-linux" ]; }; diff --git a/configs/home-manager/foo-dogsquared/modules/dotfiles.nix b/configs/home-manager/foo-dogsquared/modules/dotfiles.nix index a13ae78d..1a3a64a8 100644 --- a/configs/home-manager/foo-dogsquared/modules/dotfiles.nix +++ b/configs/home-manager/foo-dogsquared/modules/dotfiles.nix @@ -12,18 +12,15 @@ in lib.mkEnableOption "custom outside dotfiles for other programs"; config = lib.mkIf cfg.enable { - # Fetching my dotfiles,... home.mutableFile."library/dotfiles" = { url = "https://github.com/foo-dogsquared/dotfiles.git"; type = "git"; }; - # Add the custom scripts here. home.sessionPath = [ "${config.home.mutableFile."library/dotfiles".path}/bin" ]; - # All of the personal configurations. xdg.configFile = { doom.source = lib.mkIf userCfg.programs.doom-emacs.enable (getDotfiles "emacs"); diff --git a/modules/home-manager/_private/profiles/dev.nix b/modules/home-manager/_private/profiles/dev.nix index 4f6fdc75..646db5e8 100644 --- a/modules/home-manager/_private/profiles/dev.nix +++ b/modules/home-manager/_private/profiles/dev.nix @@ -215,7 +215,7 @@ in { home.packages = with pkgs; [ fastfetch # Fetch, fast! asciiquarium-transparent # The closest thing to an actual aquarium (without the responsibility, of course). - cowsay # Cow say "WHUT?" + cowsay # "WHUUUUUUUUUUUUUUUUUUUUUT?" krabby # Kapture them Pikachus, bruh. lavat # Where the lava at? ]; diff --git a/modules/nixos/programs/gnome-session/default.nix b/modules/nixos/programs/gnome-session/default.nix index dbce644e..ed27377b 100644 --- a/modules/nixos/programs/gnome-session/default.nix +++ b/modules/nixos/programs/gnome-session/default.nix @@ -26,12 +26,16 @@ in the built-in and the systemd-managed GNOME session. Each of the attribute name will be used as the identifier of the - desktop environment. While you can make identifiers in any way, it is + desktop environment. + + ::: {.tip} + While you can make identifiers in any way, it is encouraged to stick to a naming scheme. Here's two common ways to name a desktop environment. * Reverse DNS-like scheme (e.g., `com.example.MoseyBranch`). * Kebab-case (e.g., `mosey-branch`). + ::: ''; default = { }; example = lib.literalExpression '' diff --git a/modules/nixos/programs/gnome-session/submodules.nix b/modules/nixos/programs/gnome-session/submodules.nix index c657686d..f38379ab 100644 --- a/modules/nixos/programs/gnome-session/submodules.nix +++ b/modules/nixos/programs/gnome-session/submodules.nix @@ -337,6 +337,9 @@ rec { unitConfig.CollectMode = lib.mkForce "inactive-or-failed"; }; + # Luckily, this script can be flexible both for built-in and + # systemd-managed sessions by checking `DESKTOP_AUTOSTART_ID` envvar + # that is initialized with the built-in-managed session. scriptPackage = pkgs.writeShellApplication { name = scriptName; runtimeInputs = [ cfg.package pkgs.dbus ]; @@ -526,7 +529,6 @@ rec { * The display session (`.desktop`) files. * gnome-session `.session` file. - * The gnome-session systemd target drop-in file. * The components `.desktop` file. ''; readOnly = true; @@ -546,14 +548,6 @@ rec { # Append the session argument. extraArgs = [ "--session=${name}" ]; - # While it is tempting to have this delegated to `systemd.user.services` - # and the like, it does have a future problem regarding how the generated - # units will handle reload on change since NixOS systemd units lets you - # have that option. Restricting it ourselves prevent it from doing so. - # - # As a (HUGE) bonus, it also leads to a more elegant solution of making - # an entire package of the desktop environment and simply linking them - # with various NixOS options like `systemd.packages` and the like. systemdUserUnits = let inherit (utils.systemdUtils.lib)