diff --git a/default.nix b/default.nix index efbb9c5..1792790 100644 --- a/default.nix +++ b/default.nix @@ -1,47 +1,22 @@ let - inherit (builtins) - filter - fromJSON - readFile - ; + inherit (builtins) filter mapAttrs; - /* - The *sole* use for the flake in this repository is easy locking - of dependencies and inputs for nil, my lsp. - I parse the flake.lock here, extract the Lix project's - flake-compat, which features lazy store copies, aka lazy trees. + # https://github.com/andir/npins?tab=readme-ov-file#using-the-nixpkgs-fetchers + src = import ./npins; + pkgs = import src.nixpkgs { }; + sources = mapAttrs (_: v: v { inherit pkgs; }) src; - Using that, I can use Lix as my CppNix implementation - AND have lazy trees for basically free. - */ - lockFile = fromJSON (readFile ./flake.lock); - node = lockFile.nodes.root.inputs.__flake-compat; - inherit (lockFile.nodes.${node}.locked) narHash rev url; - - flake-compat = builtins.fetchTarball { - url = "${url}/archive/${rev}.tar.gz"; - sha256 = narHash; - }; - flake = import flake-compat { - src = ./.; - # Prevent eager store copies - copySourceTreeToStore = false; - useBuiltinsFetchTree = true; - }; - inherit (flake) inputs; - - pkgs = import inputs.nixpkgs { }; inherit (pkgs) lib; inherit (lib.filesystem) listFilesRecursive; inherit (lib.strings) hasSuffix; inherit (lib.attrsets) genAttrs; - nixosSystem = import (inputs.nixpkgs.outPath + "/nixos/lib/eval-config.nix"); + nixosSystem = import (sources.nixpkgs + "/nixos/lib/eval-config.nix"); mkSystem = hostname: nixosSystem { specialArgs = { - inherit inputs; + inherit sources; self = ./.; }; modules = [ @@ -49,12 +24,6 @@ let ./hosts/${hostname} ] ++ ((listFilesRecursive ./modules) |> filter (hasSuffix ".mod.nix")); - lib = inputs.nixpkgs.lib.extend ( - final: prev: { - getFlakePkg = p: p.packages.${builtins.currentSystem}.default; - getFlakePkg' = p: n: p.packages.${builtins.currentSystem}.${n}; - } - ); }; hosts = [ diff --git a/flake.lock b/flake.lock index 9ee60ba..c33cc06 100644 --- a/flake.lock +++ b/flake.lock @@ -31,29 +31,6 @@ "type": "github" } }, - "fenix": { - "inputs": { - "nixpkgs": [ - "niri-tag", - "naersk", - "nixpkgs" - ], - "rust-analyzer-src": "rust-analyzer-src" - }, - "locked": { - "lastModified": 1752475459, - "narHash": "sha256-z6QEu4ZFuHiqdOPbYss4/Q8B0BFhacR8ts6jO/F/aOU=", - "owner": "nix-community", - "repo": "fenix", - "rev": "bf0d6f70f4c9a9cf8845f992105652173f4b617f", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "fenix", - "type": "github" - } - }, "flake-compat": { "flake": false, "locked": { @@ -247,25 +224,6 @@ "type": "github" } }, - "naersk": { - "inputs": { - "fenix": "fenix", - "nixpkgs": "nixpkgs_3" - }, - "locked": { - "lastModified": 1752689277, - "narHash": "sha256-uldUBFkZe/E7qbvxa3mH1ItrWZyT6w1dBKJQF/3ZSsc=", - "owner": "nix-community", - "repo": "naersk", - "rev": "0e72363d0938b0208d6c646d10649164c43f4d64", - "type": "github" - }, - "original": { - "owner": "nix-community", - "repo": "naersk", - "type": "github" - } - }, "nh": { "inputs": { "nixpkgs": [ @@ -306,99 +264,6 @@ "type": "github" } }, - "niri": { - "inputs": { - "niri-stable": "niri-stable", - "niri-unstable": "niri-unstable", - "nixpkgs": "nixpkgs_2", - "nixpkgs-stable": "nixpkgs-stable", - "xwayland-satellite-stable": "xwayland-satellite-stable", - "xwayland-satellite-unstable": "xwayland-satellite-unstable" - }, - "locked": { - "lastModified": 1756801989, - "narHash": "sha256-eOIQ1CUMHwU4zsBGaCj9jCgNTxzyq2aeHuwgx0xLFwo=", - "owner": "sodiboo", - "repo": "niri-flake", - "rev": "d6a98b86d86b512c6167601ea646ab785137bada", - "type": "github" - }, - "original": { - "owner": "sodiboo", - "repo": "niri-flake", - "type": "github" - } - }, - "niri-stable": { - "flake": false, - "locked": { - "lastModified": 1756556321, - "narHash": "sha256-RLD89dfjN0RVO86C/Mot0T7aduCygPGaYbog566F0Qo=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "01be0e65f4eb91a9cd624ac0b76aaeab765c7294", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "ref": "v25.08", - "repo": "niri", - "type": "github" - } - }, - "niri-tag": { - "inputs": { - "naersk": "naersk", - "niri": "niri_2", - "nixpkgs": "nixpkgs_4", - "systems": "systems_3" - }, - "locked": { - "lastModified": 1755582059, - "narHash": "sha256-fDyhFfRazK2SvPQVGi6tcMTpOAu6CoUhZSyaaE2edtE=", - "ref": "refs/heads/main", - "rev": "0c1a104cea3de07c3416edb0d16db324daf5f61f", - "revCount": 37, - "type": "git", - "url": "https://git.atagen.co/atagen/niri-tag" - }, - "original": { - "type": "git", - "url": "https://git.atagen.co/atagen/niri-tag" - } - }, - "niri-unstable": { - "flake": false, - "locked": { - "lastModified": 1756728273, - "narHash": "sha256-7tYNlNO/qVRA6shdWxNuBMYOE+pGgxqE0f54S4Wr9PE=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "77465e11fe36fdd9bc0a304b96bb2558116568af", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "repo": "niri", - "type": "github" - } - }, - "niri_2": { - "flake": false, - "locked": { - "lastModified": 1755539138, - "narHash": "sha256-8LoWAwBqHFOM1Je3b+XCs6gM5LbJlMfZtSpJvTe3sQk=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "43a2648e579fc81366fc81b15f834c9c9dff119b", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "repo": "niri", - "type": "github" - } - }, "nixpkgs": { "locked": { "lastModified": 1755972213, @@ -412,71 +277,7 @@ "url": "https://channels.nixos.org/nixos-unstable-small/nixexprs.tar.xz" } }, - "nixpkgs-stable": { - "locked": { - "lastModified": 1756754095, - "narHash": "sha256-9Rsn9XEWINExosFkKEqdp8EI6Mujr1gmQiyrEcts2ls=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "7c815e513adbf03c9098b2bd230c1e0525c8a7f9", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-25.05", - "repo": "nixpkgs", - "type": "github" - } - }, "nixpkgs_2": { - "locked": { - "lastModified": 1756542300, - "narHash": "sha256-tlOn88coG5fzdyqz6R93SQL5Gpq+m/DsWpekNFhqPQk=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "d7600c775f877cd87b4f5a831c28aa94137377aa", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_3": { - "locked": { - "lastModified": 1752077645, - "narHash": "sha256-HM791ZQtXV93xtCY+ZxG1REzhQenSQO020cu6rHtAPk=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "be9e214982e20b8310878ac2baa063a961c1bdf6", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_4": { - "locked": { - "lastModified": 1756696532, - "narHash": "sha256-6FWagzm0b7I/IGigOv9pr6LL7NQ86mextfE8g8Q6HBg=", - "owner": "nixos", - "repo": "nixpkgs", - "rev": "58dcbf1ec551914c3756c267b8b9c8c86baa1b2f", - "type": "github" - }, - "original": { - "owner": "nixos", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_5": { "locked": { "lastModified": 315532800, "narHash": "sha256-JaSDu+RYnaHrkMCcW95rc8pG9QjD7nzX+/VHleiPVxA=", @@ -489,7 +290,7 @@ "url": "https://channels.nixos.org/nixpkgs-unstable/nixexprs.tar.xz" } }, - "nixpkgs_6": { + "nixpkgs_3": { "locked": { "lastModified": 1754214453, "narHash": "sha256-Q/I2xJn/j1wpkGhWkQnm20nShYnG7TI99foDBpXm1SY=", @@ -560,9 +361,7 @@ "lanzaboote": "lanzaboote", "nh": "nh", "nil": "nil", - "niri": "niri", - "niri-tag": "niri-tag", - "nixpkgs": "nixpkgs_5", + "nixpkgs": "nixpkgs_2", "quickshell": "quickshell", "sops-nix": "sops-nix", "watt": "watt", @@ -570,23 +369,6 @@ "zen-browser-flake": "zen-browser-flake" } }, - "rust-analyzer-src": { - "flake": false, - "locked": { - "lastModified": 1752428706, - "narHash": "sha256-EJcdxw3aXfP8Ex1Nm3s0awyH9egQvB2Gu+QEnJn2Sfg=", - "owner": "rust-lang", - "repo": "rust-analyzer", - "rev": "591e3b7624be97e4443ea7b5542c191311aa141d", - "type": "github" - }, - "original": { - "owner": "rust-lang", - "ref": "nightly", - "repo": "rust-analyzer", - "type": "github" - } - }, "rust-overlay": { "inputs": { "nixpkgs": [ @@ -703,21 +485,6 @@ "type": "github" } }, - "systems_3": { - "locked": { - "lastModified": 1689347949, - "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", - "owner": "nix-systems", - "repo": "default-linux", - "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default-linux", - "type": "github" - } - }, "watt": { "inputs": { "nixpkgs": [ @@ -738,43 +505,10 @@ "type": "github" } }, - "xwayland-satellite-stable": { - "flake": false, - "locked": { - "lastModified": 1755491097, - "narHash": "sha256-m+9tUfsmBeF2Gn4HWa6vSITZ4Gz1eA1F5Kh62B0N4oE=", - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "rev": "388d291e82ffbc73be18169d39470f340707edaa", - "type": "github" - }, - "original": { - "owner": "Supreeeme", - "ref": "v0.7", - "repo": "xwayland-satellite", - "type": "github" - } - }, - "xwayland-satellite-unstable": { - "flake": false, - "locked": { - "lastModified": 1756679414, - "narHash": "sha256-yQGJ/n6mRwoIQnaL5oV2TGOHg4SEHpINTaoHrvkjr1Q=", - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "rev": "c0497c990d46fcc012d9deff885bbe533e91e044", - "type": "github" - }, - "original": { - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "type": "github" - } - }, "zedless": { "inputs": { "flake-compat": "flake-compat_3", - "nixpkgs": "nixpkgs_6" + "nixpkgs": "nixpkgs_3" }, "locked": { "lastModified": 1754831523, diff --git a/flake.nix b/flake.nix index dded9b9..476db41 100644 --- a/flake.nix +++ b/flake.nix @@ -60,13 +60,6 @@ url = "git+https://git.lix.systems/lix-project/flake-compat.git"; flake = false; }; - - niri.url = "github:sodiboo/niri-flake"; - - niri-tag = { - url = "git+https://git.atagen.co/atagen/niri-tag"; - # inputs.nixpkgs.follows = "nixpkgs"; - }; }; outputs = _: { }; diff --git a/hosts/hermit/programs.nix b/hosts/hermit/programs.nix index 7b3e61c..ab73f78 100644 --- a/hosts/hermit/programs.nix +++ b/hosts/hermit/programs.nix @@ -33,6 +33,7 @@ impala imv inetutils + jujutsu just keepassxc lazygit diff --git a/hosts/temperance/programs.nix b/hosts/temperance/programs.nix index 75478fe..139359f 100644 --- a/hosts/temperance/programs.nix +++ b/hosts/temperance/programs.nix @@ -29,6 +29,7 @@ imv inetutils inshellisense + jujutsu just keepassxc lazygit diff --git a/hosts/world/programs.nix b/hosts/world/programs.nix index 01dfce1..dd35220 100644 --- a/hosts/world/programs.nix +++ b/hosts/world/programs.nix @@ -21,6 +21,7 @@ img2pdf imv inetutils + jujutsu just lazygit libtool diff --git a/modules/home/nushell/config.nu b/modules/home/nushell/config.nu index 3bb5cd7..5bc1380 100644 --- a/modules/home/nushell/config.nu +++ b/modules/home/nushell/config.nu @@ -207,8 +207,7 @@ let menus = [ only_buffer_difference: false marker: $"(ansi yellow)╋ " type: { - layout: columnar - columns: 3 + layout: ide min_completion_width: 0 max_completion_width: 150 max_completion_height: 25 @@ -273,44 +272,17 @@ if not ($env_vars_file | path exists) { | open $in | str trim | lines - | str replace --all '$HOME' $env.HOME - | str replace --all '$USER' $env.USER | parse 'export {name}="{value}"' | transpose --header-row --as-record | tee { load-env $in } | to nuon - | save --force $env_vars_file} else { + | save --force $env_vars_file +} else { open $env_vars_file | from nuon | load-env $in } - -let converter = { - from_string: {|s| $s | split row (char esep) | path expand --no-symlink } - to_string: {|v| $v | path expand --no-symlink | str join (char esep) } -} - -let addition = [ - XDG_DATA_DIRS - XDG_CONFIG_DIRS - XCURSOR_PATH - TERMINFO_DIRS - QT_PLUGIN_PATH - QTWEBKIT_PLUGIN_PATH - QML2_IMPORT_PATH - INFOPATH - LIBEXEC_PATH - GTK_PATH - GIO_EXTRA_MODULES - CUPS_DATADIR -] -| each { {($in): $converter} } -| into record - -$env.ENV_CONVERSIONS = $env.ENV_CONVERSIONS | merge $addition -$env.EDITOR = "hx" - def switch [] { nh os switch --file ($env.NH_FLAKE | path join default.nix) (open /etc/hostname | str trim) } diff --git a/modules/home/nushell/nu.hjem.nix b/modules/home/nushell/nu.hjem.nix index e57933e..6ffa828 100644 --- a/modules/home/nushell/nu.hjem.nix +++ b/modules/home/nushell/nu.hjem.nix @@ -1,6 +1,5 @@ { pkgs, - ... }: { @@ -9,8 +8,11 @@ nushell inshellisense carapace - fish ]; + environment.sessionVariables = { + CARAPACE_BRIDGES = "inshellisense,carapace,clap,bash"; + CARAPACE_MATCH = 1; + }; files = { ".config/nushell/config.nu".source = ./config.nu; diff --git a/modules/other/git.mod.nix b/modules/other/git.mod.nix index 900ba1b..6e56d9f 100644 --- a/modules/other/git.mod.nix +++ b/modules/other/git.mod.nix @@ -1,6 +1,6 @@ { pkgs, ... }: let - key = pkgs.writeText "signingkey" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILPiRe9OH/VtWFWyy5QbAVcN7CLxr4zUtRCwmxD6aeN6"; + key = pkgs.writeText "signingkey" "ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBAAWEDj/Yib6Mqs016jx7rtecWpytwfVl28eoHtPYCM9TVLq81VIHJSN37lbkc/JjiXCdIJy2Ta3A3CVV5k3Z37NbgAu23oKA2OcHQNaRTLtqWlcBf9fk9suOkP1A3NzAqzivFpBnZm3ytaXwU8LBJqxOtNqZcFVruO6fZxJtg2uE34mAw=="; in { programs.git = { diff --git a/modules/packages/packages.mod.nix b/modules/packages/packages.mod.nix index 5ccabc0..dbb6ca5 100644 --- a/modules/packages/packages.mod.nix +++ b/modules/packages/packages.mod.nix @@ -60,6 +60,7 @@ in inetutils inetutils jq + jujutsu just kondo lazygit diff --git a/modules/programs/cli/jj.mod.nix b/modules/programs/cli/jj.mod.nix index 975ad76..80b06e5 100644 --- a/modules/programs/cli/jj.mod.nix +++ b/modules/programs/cli/jj.mod.nix @@ -6,56 +6,75 @@ }: let inherit (lib.meta) getExe; - inherit (builtins) attrValues readFile; - - inherit (config.meta.mainUser) username; - - realName = readFile config.sops.secrets.real_name.path; - universityEmail = readFile config.sops.secrets.university_email.path; - organizationEmail = readFile config.sops.secrets.organization_email.path; - organizationShortName = readFile config.sops.secrets.organization_short_name.path; toml = pkgs.formats.toml { }; jj-config = toml.generate "config.toml" { user = { - email = "fau@faukah.com"; - name = "faukah"; + name = "Bloxx12"; + email = "charlie@charlieroot.dev"; }; - "--scope" = [ - { - "--when".repositories = [ "~/repos/projects/uni" ]; - user = { - email = universityEmail; - name = realName; - }; - } - { - "--when".repositories = [ "~/repos/projects/${organizationShortName}" ]; + ui = { + pager = [ + "${getExe pkgs.bat}" + "--plain" + ]; + default-command = "log"; + movement.edit = true; + + diff.tool = [ + "${getExe pkgs.difftastic}" + "--color" + "always" + "$left" + "$right" + ]; + }; + # FIXME: do this with agenix + # "--scope" = [ + # { + # "--when.repositories" = ["~/repos/projects/uni"]; + # user = { + # # TODO + # name = ""; + # email = ""; + # }; + # } + # { + # "--when.repositories" = ["~/repos/projects/uni/"]; + # user = { + # # TODO + # name = ""; + # email = ""; + # }; + # } + # ]; + git.push-new-bookmarks = true; + + signing = { + behaviour = "own"; + backend = "ssh"; + key = [ + "ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBAAWEDj/Yib6Mqs016jx7rtecWpytwfVl28eoHtPYCM9TVLq81VIHJSN37lbkc/JjiXCdIJy2Ta3A3CVV5k3Z37NbgAu23oKA2OcHQNaRTLtqWlcBf9fk9suOkP1A3NzAqzivFpBnZm3ytaXwU8LBJqxOtNqZcFVruO6fZxJtg2uE34mAw==" + ]; + }; - user = { - email = organizationEmail; - name = realName; - }; - } - ]; aliases = { c = [ "commit" ]; ci = [ "commit" "--interactive" ]; + e = [ "edit" ]; - i = [ - "git" - "init" - "--colocate" - ]; + + # "new bookmark" nb = [ "bookmark" "create" "-r @-" ]; + pull = [ "git" "fetch" @@ -65,12 +84,14 @@ let "push" "--allow-new" ]; + r = [ "rebase" ]; s = [ "squash" ]; si = [ "squash" "--interactive" ]; + tug = [ "bookmark" "move" @@ -80,17 +101,10 @@ let "@-" ]; }; - git.push-new-bookmarks = true; - revset-aliases."closest_bookmark(to)" = "heads(::to & bookmarks())"; - signing = { - backend = "ssh"; - behavior = "drop"; - key = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILPiRe9OH/VtWFWyy5QbAVcN7CLxr4zUtRCwmxD6aeN6"; - }; - template-aliases = { - "format_short_id(id)" = "id.shortest()"; - "format_timestamp(timestamp)" = "timestamp.ago()"; + revset-aliases = { + "closest_bookmark(to)" = "heads(::to & bookmarks())"; }; + templates = { draft_commit_description = '' concat( @@ -104,27 +118,22 @@ let ) ''; }; - ui = { - default-command = "log"; - diff-formatter = [ - "${getExe pkgs.difftastic}" - "--color" - "always" - "$left" - "$right" - ]; - movement = { - edit = true; - }; - pager = [ - "${getExe pkgs.bat}" - "--plain" - ]; + template-aliases = { + "format_short_id(id)" = "id.shortest()"; }; }; + jj-wrapped = pkgs.symlinkJoin { + name = "jj-wrapped"; + paths = [ pkgs.jj ]; + nativeBuildInputs = [ pkgs.makeWrapper ]; + postBuild = '' + wrapProgram $out/bin/mako --add-flags "\ + --config ${jj-config} + + ''; + }; in { - hjem.users.${username}.xdg.config.files."jj/config.toml".source = jj-config; - environment.systemPackages = attrValues { inherit (pkgs) jujutsu; }; + # environment.systemPackages = [jj-wrapped]; } diff --git a/modules/programs/other/direnv.mod.nix b/modules/programs/other/direnv.mod.nix index 749b168..1c5e612 100644 --- a/modules/programs/other/direnv.mod.nix +++ b/modules/programs/other/direnv.mod.nix @@ -12,8 +12,7 @@ loadInNixShell = true; enableBashIntegration = false; - enableFishIntegration = true; + enableFishIntegration = false; }; - environment.systemPackages = [pkgs.fish]; }; } diff --git a/modules/system/boot/boot.mod.nix b/modules/system/boot/boot.mod.nix index 45fb99a..5c05cb8 100644 --- a/modules/system/boot/boot.mod.nix +++ b/modules/system/boot/boot.mod.nix @@ -39,7 +39,6 @@ in boot = { tmp.useTmpfs = true; consoleLogLevel = 0; - enableContainers = false; kernelParams = [ "quiet" diff --git a/modules/system/nix/nix.mod.nix b/modules/system/nix/nix.mod.nix index 225db89..dec36b6 100644 --- a/modules/system/nix/nix.mod.nix +++ b/modules/system/nix/nix.mod.nix @@ -153,7 +153,7 @@ in keep-derivations = true; keep-outputs = true; - # bash-prompt-suffix = "\[\033[m\]|\[\033[1;35m\]\t\[\033[m\]|\[\e[1m\]\u\[\e[1;36m\]\[\033[m\]@\[\e[1;36m\]\h\[\033[m\]:\[\e[0m\]\[\e[1;32m\][\W]> \[\e[0m\]"; + bash-prompt-suffix = "\[\033[m\]|\[\033[1;35m\]\t\[\033[m\]|\[\e[1m\]\u\[\e[1;36m\]\[\033[m\]@\[\e[1;36m\]\h\[\033[m\]:\[\e[0m\]\[\e[1;32m\][\W]> \[\e[0m\]"; # Use binary cache builders-use-substitutes = true; diff --git a/modules/system/nix/nixpkgs.mod.nix b/modules/system/nix/nixpkgs.mod.nix index 2fe6db0..ffec8fb 100644 --- a/modules/system/nix/nixpkgs.mod.nix +++ b/modules/system/nix/nixpkgs.mod.nix @@ -51,7 +51,7 @@ in # Whether to expose old attribute names for compatibility. # This improves backwards compatibility, # which I could not care less about in my configuration. - allowAliases = true; + allowAliases = false; # List of derivation warnings to display while rebuilding. # See: diff --git a/modules/system/secrets/personal_info.json b/modules/system/secrets/personal_info.json index 7315fc6..5bbebd7 100644 --- a/modules/system/secrets/personal_info.json +++ b/modules/system/secrets/personal_info.json @@ -1,24 +1,24 @@ { - "real_name": "ENC[AES256_GCM,data:R7Kac0dwMbxmCw4hpw==,iv:CijNtk8WiPlEwIg0OLu4ILLE2wh0W9HXm9OK9/Da+ng=,tag:NK2N6faooEknURwLuVP7OQ==,type:str]", - "real_email": "ENC[AES256_GCM,data:wwXcdxZQDxt2gnWP1qf9cw==,iv:fkx0m72FF7pB15fHRxObsTaLdnkOsexCgzOyfpoGFmE=,tag:mj2/4cofrJSIOqdAWiWstg==,type:str]", - "university_email": "ENC[AES256_GCM,data:WPy2AckQPWn+1OHJuTM=,iv:o2AT+RMUfCFVWaoD5D/GV5aq9kOgD/rCaHzwqYFIjig=,tag:KprTGSH2NvsrOCvhxLL/9w==,type:str]", - "organization_short_name": "ENC[AES256_GCM,data:dTVFz51V,iv:5sUc4qUIu+QNzmWihAXgyfRwZAdjEq9/prJCxpB2jbg=,tag:r91kaPi6p4heizRy5duFrw==,type:str]", - "organization_email": "ENC[AES256_GCM,data:GNBt9fXxBkh3z8L+DeD/mhBz14mJjkeX1wk9rHkUTg==,iv:7/VLeL3s9/CL2VtDiWFJNx+VJuGsGamWbcIG/MxNlC8=,tag:/KOXA6gII3Wrmgd9wjhD+g==,type:str]", - "bitwarden_url": "ENC[AES256_GCM,data:vhEVMZwDyQhQtXYR1diLQIDf6urqu03VC+M=,iv:icG6ieX9WjAj5Y4DpmSJaBvcqjksll3tWtWE5psaK08=,tag:+tIURDxZxv6qXR8B/eVyfg==,type:str]", - "sops": { - "age": [ - { - "recipient": "age1a4jv2avdlj5zzq9p7ss9958t4wt3an95c3j86eclge7q2qc6n3wq4ucymc", - "enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBYZzJqMmdzdklJVXBWaXFr\nTlJuVVIvTEhndkhyWWEvb1JzbnJuQ2NrTDI4ClVxYUNTSms2Y29xV3RkbTlFR0Fl\nS3p2dlFVTnp0bmhsRVk5eGJNR0s0SzAKLS0tIHpkTTJ4djg3K2FSNFM2RDFXbWd5\neFpsMUdRczZpSnY0eE41WGtyQmI2amMKx+TPSzzdaXWc24ibbbI44O0Tg23MlQk7\nypgcVAaG+Q1HyBH2hZ+6HNAXIvko4CvAQu2kjipN8kN1vVFVO7pM8A==\n-----END AGE ENCRYPTED FILE-----\n" - }, - { - "recipient": "age12neldqxts6h3zstmk5hvmn2pq8s9qfhkt7cjcdd9wygekqrmparq6djsff", - "enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBBL1ExSlArditYSytuUzNC\nMEpVSUVGbGhkNklmT1ZnK1VJWGxGZWlreUFNClU1NjdPdHNPRVlWa0tCdjRvRDNY\nMFpSajY0d21ZTnFVbDZkSG4yS3ZkZmMKLS0tIGdLK1B2TUZyWXVHNkhRWkVIRVFJ\nWEtpS2NEanIzR3YzVHhDOVc0WTgzdHcKXrFMFf5niLKK+oN2RbpH5wy/2SjDuP8O\nyxUdKX9R0Hu2ZPk4cJXwn/PZDNP1M3wFlPnF+kJ4bSBRzV+M51W2jw==\n-----END AGE ENCRYPTED FILE-----\n" - } - ], - "lastmodified": "2025-09-01T21:25:00Z", - "mac": "ENC[AES256_GCM,data:CUMEpOwIw+/RIOyr6aE2YVZiJLGY8FhMv0IOUIFV1kHveOEtAkNWbRzOV1o1cq9pA9ot0dKn4KZRLuUZ+uJzCrxwBHILBZMFksS0czSPgLfg0uz9mJ2u1pPjvoUcQRuIOUN1Id32zQ/W36nPEpR3J/Jomx5nCVNiFmZSteZCx+E=,iv:wGzjsGMJ72ejDCiHN6Xo1ZP5ho1F++WZrwE2YwCN8ns=,tag:Ev1xjuwta6KL8lnPbhliyw==,type:str]", - "unencrypted_suffix": "_unencrypted", - "version": "3.10.2" - } + "real_name": "ENC[AES256_GCM,data:R7Kac0dwMbxmCw4hpw==,iv:CijNtk8WiPlEwIg0OLu4ILLE2wh0W9HXm9OK9/Da+ng=,tag:NK2N6faooEknURwLuVP7OQ==,type:str]", + "real_email": "ENC[AES256_GCM,data:wwXcdxZQDxt2gnWP1qf9cw==,iv:fkx0m72FF7pB15fHRxObsTaLdnkOsexCgzOyfpoGFmE=,tag:mj2/4cofrJSIOqdAWiWstg==,type:str]", + "university_email": "ENC[AES256_GCM,data:WPy2AckQPWn+1OHJuTM=,iv:o2AT+RMUfCFVWaoD5D/GV5aq9kOgD/rCaHzwqYFIjig=,tag:KprTGSH2NvsrOCvhxLL/9w==,type:str]", + "organization_short_name": "ENC[AES256_GCM,data:dTVFz51V,iv:5sUc4qUIu+QNzmWihAXgyfRwZAdjEq9/prJCxpB2jbg=,tag:r91kaPi6p4heizRy5duFrw==,type:str]", + "organization_email": "ENC[AES256_GCM,data:GNBt9fXxBkh3z8L+DeD/mhBz14mJjkeX1wk9rHkUTg==,iv:7/VLeL3s9/CL2VtDiWFJNx+VJuGsGamWbcIG/MxNlC8=,tag:/KOXA6gII3Wrmgd9wjhD+g==,type:str]", + "bitwarden_url": "ENC[AES256_GCM,data:vhEVMZwDyQhQtXYR1diLQIDf6urqu03VC+M=,iv:icG6ieX9WjAj5Y4DpmSJaBvcqjksll3tWtWE5psaK08=,tag:+tIURDxZxv6qXR8B/eVyfg==,type:str]", + "sops": { + "age": [ + { + "recipient": "age1a4jv2avdlj5zzq9p7ss9958t4wt3an95c3j86eclge7q2qc6n3wq4ucymc", + "enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBYZzJqMmdzdklJVXBWaXFr\nTlJuVVIvTEhndkhyWWEvb1JzbnJuQ2NrTDI4ClVxYUNTSms2Y29xV3RkbTlFR0Fl\nS3p2dlFVTnp0bmhsRVk5eGJNR0s0SzAKLS0tIHpkTTJ4djg3K2FSNFM2RDFXbWd5\neFpsMUdRczZpSnY0eE41WGtyQmI2amMKx+TPSzzdaXWc24ibbbI44O0Tg23MlQk7\nypgcVAaG+Q1HyBH2hZ+6HNAXIvko4CvAQu2kjipN8kN1vVFVO7pM8A==\n-----END AGE ENCRYPTED FILE-----\n" + }, + { + "recipient": "age12neldqxts6h3zstmk5hvmn2pq8s9qfhkt7cjcdd9wygekqrmparq6djsff", + "enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBBL1ExSlArditYSytuUzNC\nMEpVSUVGbGhkNklmT1ZnK1VJWGxGZWlreUFNClU1NjdPdHNPRVlWa0tCdjRvRDNY\nMFpSajY0d21ZTnFVbDZkSG4yS3ZkZmMKLS0tIGdLK1B2TUZyWXVHNkhRWkVIRVFJ\nWEtpS2NEanIzR3YzVHhDOVc0WTgzdHcKXrFMFf5niLKK+oN2RbpH5wy/2SjDuP8O\nyxUdKX9R0Hu2ZPk4cJXwn/PZDNP1M3wFlPnF+kJ4bSBRzV+M51W2jw==\n-----END AGE ENCRYPTED FILE-----\n" + } + ], + "lastmodified": "2025-09-01T21:25:00Z", + "mac": "ENC[AES256_GCM,data:CUMEpOwIw+/RIOyr6aE2YVZiJLGY8FhMv0IOUIFV1kHveOEtAkNWbRzOV1o1cq9pA9ot0dKn4KZRLuUZ+uJzCrxwBHILBZMFksS0czSPgLfg0uz9mJ2u1pPjvoUcQRuIOUN1Id32zQ/W36nPEpR3J/Jomx5nCVNiFmZSteZCx+E=,iv:wGzjsGMJ72ejDCiHN6Xo1ZP5ho1F++WZrwE2YwCN8ns=,tag:Ev1xjuwta6KL8lnPbhliyw==,type:str]", + "unencrypted_suffix": "_unencrypted", + "version": "3.10.2" + } } diff --git a/modules/wms/niri/config.nix b/modules/wms/niri/config.nix index 5bdc799..04a3183 100644 --- a/modules/wms/niri/config.nix +++ b/modules/wms/niri/config.nix @@ -5,8 +5,6 @@ plain, leaf, flag, - tagctl, - }: let inherit (lib.meta) getExe getExe'; @@ -59,11 +57,8 @@ in }) ]) - (flag "prefer-no-csd") - (leaf "screenshot-path" "~/Pictures/Screenshots/Screenshot from %Y-%m-%d %H-%M-%S.png") - (plain "layout" [ - (leaf "gaps" 15) + (leaf "gaps" 0) (leaf "center-focused-column" "on-overflow") (plain "focus-ring" [ @@ -120,6 +115,7 @@ in (leaf "match" { namespace = "overview$"; }) (leaf "place-within-backdrop" true) ]) + (flag "prefer-no-csd") (plain "switch-events" [ (plain "lid-close" [ (leaf "spawn" <| getExe pkgs.swaylock) @@ -131,7 +127,7 @@ in ]) (plain "animations" [ - # (flag "off") + (flag "off") (plain "window-close" [ (leaf "duration-ms" 250) (leaf "curve" "linear") @@ -153,6 +149,7 @@ in (leaf "draw-border-with-background" false) ]) (plain "debug" [ + (flag "wait-for-frame-completion-in-pipewire") ]) (plain "hotkey-overlay" [ (flag "skip-at-startup") @@ -231,62 +228,17 @@ in ]) ]) - (plain "Mod+0" [ (leaf "spawn" [tagctl "toggle-tag" "0"]) ]) - (plain "Mod+1" [ (leaf "spawn" [tagctl "toggle-tag" "1"]) ]) - (plain "Mod+2" [ (leaf "spawn" [tagctl "toggle-tag" "2"]) ]) - (plain "Mod+3" [ (leaf "spawn" [tagctl "toggle-tag" "3"]) ]) - (plain "Mod+4" [ (leaf "spawn" [tagctl "toggle-tag" "4"]) ]) - (plain "Mod+5" [ (leaf "spawn" [tagctl "toggle-tag" "5"]) ]) - (plain "Mod+6" [ (leaf "spawn" [tagctl "toggle-tag" "6"]) ]) - (plain "Mod+7" [ (leaf "spawn" [tagctl "toggle-tag" "7"]) ]) - (plain "Mod+8" [ (leaf "spawn" [tagctl "toggle-tag" "8"]) ]) - (plain "Mod+9" [ (leaf "spawn" [tagctl "toggle-tag" "9"]) ]) - - # (plain "Mod+0" [ (leaf "focus-workspace" 0) ]) - # (plain "Mod+1" [ (leaf "focus-workspace" 1) ]) - # (plain "Mod+2" [ (leaf "focus-workspace" 2) ]) - # (plain "Mod+3" [ (leaf "focus-workspace" 3) ]) - # (plain "Mod+4" [ (leaf "focus-workspace" 4) ]) - # (plain "Mod+5" [ (leaf "focus-workspace" 5) ]) - # (plain "Mod+6" [ (leaf "focus-workspace" 6) ]) - # (plain "Mod+7" [ (leaf "focus-workspace" 7) ]) - # (plain "Mod+8" [ (leaf "focus-workspace" 8) ]) - # (plain "Mod+9" [ (leaf "focus-workspace" 9) ]) - # - (plain "Mod+Shift+0" [ (leaf "spawn" [tagctl "toggle" "0"]) ]) - (plain "Mod+Shift+1" [ (leaf "spawn" [tagctl "toggle" "1"]) ]) - (plain "Mod+Shift+2" [ (leaf "spawn" [tagctl "toggle" "2"]) ]) - (plain "Mod+Shift+3" [ (leaf "spawn" [tagctl "toggle" "3"]) ]) - (plain "Mod+Shift+4" [ (leaf "spawn" [tagctl "toggle" "4"]) ]) - (plain "Mod+Shift+5" [ (leaf "spawn" [tagctl "toggle" "5"]) ]) - (plain "Mod+Shift+6" [ (leaf "spawn" [tagctl "toggle" "6"]) ]) - (plain "Mod+Shift+7" [ (leaf "spawn" [tagctl "toggle" "7"]) ]) - (plain "Mod+Shift+8" [ (leaf "spawn" [tagctl "toggle" "8"]) ]) - (plain "Mod+Shift+9" [ (leaf "spawn" [tagctl "toggle" "9"]) ]) - - # (plain "Mod+Shift+0" [ (leaf "move-column-to-workspace" 0) ]) - # (plain "Mod+Shift+1" [ (leaf "move-column-to-workspace" 1) ]) - # (plain "Mod+Shift+2" [ (leaf "move-column-to-workspace" 2) ]) - # (plain "Mod+Shift+3" [ (leaf "move-column-to-workspace" 3) ]) - # (plain "Mod+Shift+4" [ (leaf "move-column-to-workspace" 4) ]) - # (plain "Mod+Shift+5" [ (leaf "move-column-to-workspace" 5) ]) - # (plain "Mod+Shift+6" [ (leaf "move-column-to-workspace" 6) ]) - # (plain "Mod+Shift+7" [ (leaf "move-column-to-workspace" 7) ]) - # (plain "Mod+Shift+8" [ (leaf "move-column-to-workspace" 8) ]) - # (plain "Mod+Shift+9" [ (leaf "move-column-to-workspace" 9) ]) - - (plain "Mod+Ctrl+0" [ (leaf "spawn" [tagctl "exclusive-tag" "0"]) ]) - (plain "Mod+Ctrl+1" [ (leaf "spawn" [tagctl "exclusive-tag" "1"]) ]) - (plain "Mod+Ctrl+2" [ (leaf "spawn" [tagctl "exclusive-tag" "2"]) ]) - (plain "Mod+Ctrl+3" [ (leaf "spawn" [tagctl "exclusive-tag" "3"]) ]) - (plain "Mod+Ctrl+4" [ (leaf "spawn" [tagctl "exclusive-tag" "4"]) ]) - (plain "Mod+Ctrl+5" [ (leaf "spawn" [tagctl "exclusive-tag" "5"]) ]) - (plain "Mod+Ctrl+6" [ (leaf "spawn" [tagctl "exclusive-tag" "6"]) ]) - (plain "Mod+Ctrl+7" [ (leaf "spawn" [tagctl "exclusive-tag" "7"]) ]) - (plain "Mod+Ctrl+8" [ (leaf "spawn" [tagctl "exclusive-tag" "8"]) ]) - (plain "Mod+Ctrl+9" [ (leaf "spawn" [tagctl "exclusive-tag" "9"]) ]) - (plain "Ctrl+Print" [ (flag "screenshot-screen") ]) + (plain "Mod+0" [ (leaf "focus-workspace" 0) ]) + (plain "Mod+1" [ (leaf "focus-workspace" 1) ]) + (plain "Mod+2" [ (leaf "focus-workspace" 2) ]) + (plain "Mod+3" [ (leaf "focus-workspace" 3) ]) + (plain "Mod+4" [ (leaf "focus-workspace" 4) ]) + (plain "Mod+5" [ (leaf "focus-workspace" 5) ]) + (plain "Mod+6" [ (leaf "focus-workspace" 6) ]) + (plain "Mod+7" [ (leaf "focus-workspace" 7) ]) + (plain "Mod+8" [ (leaf "focus-workspace" 8) ]) + (plain "Mod+9" [ (leaf "focus-workspace" 9) ]) (plain "Mod+Alt+L" [ (leaf "spawn" <| getExe pkgs.swaylock) ]) (plain "Mod+B" [ (leaf "spawn" <| getExe pkgs.brave) ]) (plain "Mod+BracketLeft" [ (flag "consume-or-expel-window-left") ]) @@ -307,17 +259,27 @@ in (plain "Mod+F" [ (flag "maximize-column") ]) (plain "Mod+H" [ (flag "focus-column-or-monitor-left") ]) (plain "Mod+Home" [ (flag "focus-column-first") ]) - # (plain "Mod+I" [ (flag "focus-workspace-up") ]) + (plain "Mod+I" [ (flag "focus-workspace-up") ]) (plain "Mod+J" [ (flag "focus-window-or-workspace-down") ]) (plain "Mod+K" [ (flag "focus-window-or-workspace-up") ]) (plain "Mod+L" [ (flag "focus-column-or-monitor-right") ]) (plain "Mod+Minus" [ (leaf "set-column-width" [ "-10%" ]) ]) (plain "Mod+O" [ (flag "toggle-overview") ]) - # (plain "Mod+Page_Down" [ (flag "focus-workspace-down") ]) - # (plain "Mod+Page_Up" [ (flag "focus-workspace-up") ]) + (plain "Mod+Page_Down" [ (flag "focus-workspace-down") ]) + (plain "Mod+Page_Up" [ (flag "focus-workspace-up") ]) (plain "Mod+Period" [ (flag "expel-window-from-column") ]) (plain "Mod+Q" [ (flag "close-window") ]) (plain "Mod+R" [ (flag "switch-preset-column-width") ]) + (plain "Mod+Shift+0" [ (leaf "move-column-to-workspace" 0) ]) + (plain "Mod+Shift+1" [ (leaf "move-column-to-workspace" 1) ]) + (plain "Mod+Shift+2" [ (leaf "move-column-to-workspace" 2) ]) + (plain "Mod+Shift+3" [ (leaf "move-column-to-workspace" 3) ]) + (plain "Mod+Shift+4" [ (leaf "move-column-to-workspace" 4) ]) + (plain "Mod+Shift+5" [ (leaf "move-column-to-workspace" 5) ]) + (plain "Mod+Shift+6" [ (leaf "move-column-to-workspace" 6) ]) + (plain "Mod+Shift+7" [ (leaf "move-column-to-workspace" 7) ]) + (plain "Mod+Shift+8" [ (leaf "move-column-to-workspace" 8) ]) + (plain "Mod+Shift+9" [ (leaf "move-column-to-workspace" 9) ]) (plain "Mod+Shift+Ctrl+Down" [ (flag "move-column-to-monitor-down") ]) (plain "Mod+Shift+Ctrl+H" [ (flag "move-column-to-monitor-left") ]) (plain "Mod+Shift+Ctrl+J" [ (flag "move-column-to-monitor-down") ]) @@ -330,29 +292,29 @@ in (plain "Mod+Shift+Equal" [ (leaf "set-window-height" [ "+10%" ]) ]) (plain "Mod+Shift+F" [ (flag "fullscreen-window") ]) (plain "Mod+Shift+H" [ (flag "move-column-left-or-to-monitor-left") ]) - # (plain "Mod+Shift+I" [ (flag "move-column-to-workspace-up") ]) - # (plain "Mod+Shift+J" [ (flag "move-window-down-or-to-workspace-down") ]) - # (plain "Mod+Shift+K" [ (flag "move-window-up-or-to-workspace-up") ]) + (plain "Mod+Shift+I" [ (flag "move-column-to-workspace-up") ]) + (plain "Mod+Shift+J" [ (flag "move-window-down-or-to-workspace-down") ]) + (plain "Mod+Shift+K" [ (flag "move-window-up-or-to-workspace-up") ]) (plain "Mod+Shift+L" [ (flag "move-column-right-or-to-monitor-right") ]) (plain "Mod+Shift+Minus" [ (leaf "set-window-height" [ "-10%" ]) ]) - # (plain "Mod+Shift+Page_Down" [ (flag "move-column-to-workspace-down") ]) + (plain "Mod+Shift+Page_Down" [ (flag "move-column-to-workspace-down") ]) (plain "Mod+Shift+Page_Up" [ (flag "move-column-to-workspace-up") ]) (plain "Mod+Shift+P" [ (flag "power-off-monitors") ]) (plain "Mod+Shift+R" [ (flag "switch-preset-window-height") ]) - # (plain "Mod+Shift+U" [ (flag "move-column-to-workspace-down") ]) + (plain "Mod+Shift+U" [ (flag "move-column-to-workspace-down") ]) (plain "Mod+Shift+V" [ (flag "switch-focus-between-floating-and-tiling") ]) - # (plain "Mod+Shift+WheelScrollDown" [ (flag "move-column-to-workspace-down") ]) + (plain "Mod+Shift+WheelScrollDown" [ (flag "move-column-to-workspace-down") ]) (plain "Mod+Shift+WheelScrollLeft" [ (flag "move-column-left") ]) (plain "Mod+Shift+WheelScrollRight" [ (flag "move-column-right") ]) - # (plain "Mod+Shift+WheelScrollUp" [ (flag "move-column-to-workspace-up") ]) + (plain "Mod+Shift+WheelScrollUp" [ (flag "move-column-to-workspace-up") ]) (plain "Mod+T" [ (flag "screenshot") ]) (plain "Mod+U" [ (flag "focus-workspace-down") ]) (plain "Mod+V" [ (flag "toggle-window-floating") ]) (plain "Mod+W" [ (flag "toggle-column-tabbed-display") ]) - # (plain "Mod+WheelScrollDown" [ (flag "focus-workspace-down") ]) + (plain "Mod+WheelScrollDown" [ (flag "focus-workspace-down") ]) (plain "Mod+WheelScrollLeft" [ (flag "focus-column-left") ]) (plain "Mod+WheelScrollRight" [ (flag "focus-column-right") ]) - # (plain "Mod+WheelScrollUp" [ (flag "focus-workspace-up") ]) + (plain "Mod+WheelScrollUp" [ (flag "focus-workspace-up") ]) (plain "Print" [ (flag "screenshot") ]) ]) diff --git a/modules/wms/niri/niri.mod.nix b/modules/wms/niri/niri.mod.nix index dc56fed..2662967 100644 --- a/modules/wms/niri/niri.mod.nix +++ b/modules/wms/niri/niri.mod.nix @@ -1,6 +1,5 @@ { config, - inputs, lib, pkgs, ... @@ -8,13 +7,8 @@ let inherit (lib.modules) mkForce mkIf; inherit (lib.options) mkEnableOption; - inherit (lib.meta) getExe'; inherit (config.modules.system) isGraphical; inherit (config.meta.mainUser) username; - inherit (lib) getFlakePkg'; - - niri-tag = inputs.niri-tag.packages.${builtins.currentSystem}.unstable; - tagctl = getExe' niri-tag "tagctl"; cfg = config.modules.desktops.niri; @@ -56,31 +50,21 @@ let flag lib pkgs - tagctl ; } ); in { - imports = [ - inputs.niri-tag.nixosModules.niri-tag - inputs.niri.nixosModules.niri - ]; options.modules.desktops.niri.enable = mkEnableOption "Niri, a scolling tiling wayland compositor"; config = mkIf (cfg.enable || isGraphical) { programs.niri = { enable = true; - # package = pkgs.niri; - }; - services = { - # The niri module auto enables the gnome keyring, - # which is something I direly want to avoid. - gnome.gnome-keyring.enable = mkForce false; - niri-tag = { - enable = true; - }; + package = pkgs.niri; }; + # The niri module auto enables the gnome keyring, + # which is something I direly want to avoid. + services.gnome.gnome-keyring.enable = mkForce false; hjem.users.${username}.files.".config/niri/config.kdl".source = niri-config; diff --git a/modules/wms/portal.mod.nix b/modules/wms/portal.mod.nix index cfe7b3f..7160302 100644 --- a/modules/wms/portal.mod.nix +++ b/modules/wms/portal.mod.nix @@ -11,33 +11,30 @@ in { xdg.portal = { enable = true; - # Sets environment variable NIXOS_XDG_OPEN_USE_PORTAL to 1. # This will make xdg-open use the portal to open programs, # which resolves bugs involving programs opening inside FHS envs # or with unexpected env vars set from wrappers. # See #160923 for more info. xdgOpenUsePortal = true; - extraPortals = [ - pkgs.xdg-desktop-portal-gnome pkgs.xdg-desktop-portal-gtk + pkgs.kdePackages.xdg-desktop-portal-kde + pkgs.xdg-desktop-portal-gnome ]; config = { - common = { + niri = { default = [ "gnome" "gtk" + "kde" ]; - "org.freedesktop.impl.portal.Secret" = [ - "gnome-keyring" - ]; + # Portal API reference: + # https://docs.flatpak.org/en/latest/portal-api-reference.html + # "org.freedesktop.impl.portal.Access" = ["kde"]; + # "org.freedesktop.impl.portal.Notification" = ["kde"]; + "org.freedesktop.impl.portal.FileChooser" = [ "kde" ]; }; }; }; - - environment.pathsToLink = [ - "/share/xdg-desktop-portal" - "/share/applications" - ]; }