mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-04-18 06:59:43 +02:00
• Updated input 'nixpkgs':
→ 'github:NixOS/nixpkgs/0254eab410b90ef2420c1059f908ae777e3b02f9?narHash=sha256-/US2Ei9JHXHVBAxV4FX49Q7H5s4UNBrIiOA6Xjzgq44%3D' (2025-12-06)
• Updated input 'home-manager':
'github:nix-community/home-manager/f4cb25928fafa9ae68660fe71f730fc820a59028?narHash=sha256-5xOuutXM7UPTUcn3uDAD8UlPQsXmqPrX81cXoDOAGcA%3D' (2025-11-26)
→ 'github:nix-community/home-manager/89c9508bbe9b40d36b3dc206c2483ef176f15173?narHash=sha256-rB45jv4uwC90vM9UZ70plfvY/2Kdygs%2BzlQ07dGQFk4%3D' (2025-12-17)
• Updated input 'nixpkgs-master':
'github:nixos/nixpkgs/6812bcfd614abedbdb3f68d7b6554eda6ca3e014?narHash=sha256-sNF/PZcuzYBHKRBkerEiPf5mkZM15A3fWD%2BlqpwKc60%3D' (2025-12-15)
→ 'github:nixos/nixpkgs/e50ab9bb181f9fb3ce00e7a6007c70ddaa007203?narHash=sha256-acPMRCAPgPykzkwATwD1EfF7xgmbraAvIJyCeR6bKxc%3D' (2025-12-18)
Signed-off-by: Ryan Yin <xiaoyin_c@qq.com>
61 lines
1.7 KiB
Nix
61 lines
1.7 KiB
Nix
{ lib, pkgs, ... }:
|
|
{
|
|
xdg.terminal-exec = {
|
|
enable = true;
|
|
package = pkgs.xdg-terminal-exec-mkhl;
|
|
settings =
|
|
let
|
|
my_terminal_desktop = [
|
|
# NOTE: We have add these packages at user level
|
|
"Alacritty.desktop"
|
|
"kitty.desktop"
|
|
"foot.desktop"
|
|
"com.mitchellh.ghostty.desktop"
|
|
];
|
|
in
|
|
{
|
|
GNOME = my_terminal_desktop ++ [
|
|
"com.raggesilver.BlackBox.desktop"
|
|
"org.gnome.Terminal.desktop"
|
|
];
|
|
niri = my_terminal_desktop;
|
|
default = my_terminal_desktop;
|
|
};
|
|
};
|
|
|
|
xdg = {
|
|
autostart.enable = lib.mkDefault true;
|
|
menus.enable = lib.mkDefault true;
|
|
mime.enable = lib.mkDefault true;
|
|
icons.enable = lib.mkDefault true;
|
|
};
|
|
|
|
xdg.portal = {
|
|
enable = true;
|
|
|
|
config = {
|
|
common = {
|
|
# Use xdg-desktop-portal-gtk for every portal interface...
|
|
default = [
|
|
"gtk"
|
|
"gnome"
|
|
];
|
|
};
|
|
};
|
|
|
|
# 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.
|
|
# xdg-open is used by almost all programs to open a unknown file/uri
|
|
# alacritty as an example, it use xdg-open as default, but you can also custom this behavior
|
|
# and vscode has open like `External Uri Openers`
|
|
xdgOpenUsePortal = true;
|
|
|
|
# ls /run/current-system/sw/share/xdg-desktop-portal/portals/
|
|
extraPortals = with pkgs; [
|
|
xdg-desktop-portal-gtk # for provides file picker / OpenURI
|
|
xdg-desktop-portal-gnome # for screensharing
|
|
];
|
|
};
|
|
}
|