Preserve XDG_DATA_DIRS and add snapd desktop

Update flake.lock to bump nixpkgs to the new revision and narHash
This commit is contained in:
2025-12-11 13:56:57 +01:00
parent a55369070d
commit ab912c488e
3 changed files with 21 additions and 4 deletions

View File

@@ -38,7 +38,7 @@
export EDITOR="code --wait"
export STARSHIP_ENABLE_RIGHT_PROMPT="true"
export STARSHIP_ENABLE_BASH_COMPLETION="true"
export XDG_DATA_DIRS="/usr/share:/var/lib/flatpak/exports/share:${config.home.homeDirectory}/.local/share/flatpak/exports/share"
export XDG_DATA_DIRS="/usr/share:/var/lib/flatpak/exports/share:${config.home.homeDirectory}/.local/share/flatpak/exports/share:$XDG_DATA_DIRS"
export BUN_INSTALL="$HOME/.bun"
# Source .profile (If exists)

6
flake.lock generated
View File

@@ -41,11 +41,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1764316264,
"narHash": "sha256-82L+EJU+40+FIdeG4gmUlOF1jeSwlf2AwMarrpdHF6o=",
"lastModified": 1765363881,
"narHash": "sha256-3C3xWn8/2Zzr7sxVBmpc1H1QfxjNfta5IMFe3O9ZEPw=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "9a7b80b6f82a71ea04270d7ba11b48855681c4b0",
"rev": "d2b1213bf5ec5e62d96b003ab4b5cbc42abfc0d0",
"type": "github"
},
"original": {

17
workstation/snapd.nix Normal file
View File

@@ -0,0 +1,17 @@
{ config, lib, ... }:
let
# Merge our session variable into any existing ones, if present.
existingSessionVars = config.home.sessionVariables or {};
sessionVars = existingSessionVars // {
# Prepend snap desktop dir so snap-provided .desktop files are discovered by desktop environments.
# We include `$XDG_DATA_DIRS` to preserve any previously-set value at runtime.
XDG_DATA_DIRS = "/var/lib/snapd/desktop:$XDG_DATA_DIRS";
};
in
{
config = {
# Use mkForce to ensure this module's value takes precedence when modules are merged.
home.sessionVariables = lib.mkForce sessionVars;
};
}