hyprland lua dispatch

This commit is contained in:
Keisuke Hirata 2026-07-21 20:07:19 +09:00
parent 5ea08b009d
commit 4c8e9f809a
No known key found for this signature in database
7 changed files with 109 additions and 26 deletions

View File

@ -36,6 +36,24 @@
"type": "github" "type": "github"
} }
}, },
"flake-utils_3": {
"inputs": {
"systems": "systems_3"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -43,11 +61,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1780408569, "lastModified": 1784489491,
"narHash": "sha256-s7Tv6FUQThRAvW8En8XVC6HMb0uiikzVccCcCo9u/Bg=", "narHash": "sha256-j9maqjx1T8+ljAVntAdSI5hSGCm77QNZz64JF1rJNu0=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "f384af1bec6423a0d4ba1855917ab948f64e5808", "rev": "3139deb8cafbe73b39b24451255b2fdd3426077e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -63,11 +81,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1780210899, "lastModified": 1784440659,
"narHash": "sha256-4axz3OBPTKa6LIkXV8n0lc63MQU+et2CB5DGobEAi6k=", "narHash": "sha256-Q5kNLlWngt7TaIIZoxDKWMHjiSaNRVqr70FqWCRRfr4=",
"owner": "Mic92", "owner": "Mic92",
"repo": "nix-index-database", "repo": "nix-index-database",
"rev": "97df9dc0b7c924344b793a15c1e8e4522ebb854e", "rev": "4f8d52a3598b0dc7db7a5e7b419e3edd9d1ecfdb",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -81,11 +99,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1780310866, "lastModified": 1784310968,
"narHash": "sha256-fPBRVf6A5xlACYcOI59shGrjURuvwu0lRsDoSCEXt/I=", "narHash": "sha256-rkSPTePrKqs4dg+i7ZFCq93+HrClac6oSwXX927SVjA=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "4ed851c979641e28597a05086332d75cdc9e395f", "rev": "779c32a00155994c86cde8213a8dd4df139d4355",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -109,11 +127,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1780243769, "lastModified": 1784356753,
"narHash": "sha256-x5UQuRsH3MqI0U9afaXSNqzTPSeZlRLvFAav2Ux1pNw=", "narHash": "sha256-12KrbMiWLcf8m7pCvAtZh1ZrgF85ZXDXvfR/fWTKy84=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "331800de5053fcebacf6813adb5db9c9dca22a0c", "rev": "61b7c44c4073f0b827768aff0049561b5110ea5a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -124,6 +142,22 @@
} }
}, },
"nixpkgs_3": { "nixpkgs_3": {
"locked": {
"lastModified": 1781577229,
"narHash": "sha256-lrp67w8AulE9Ks53n27I45ADSzbOCn4H+CNW1Ck8B+8=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "567a49d1913ce81ac6e9582e3553dd90a955875f",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_4": {
"locked": { "locked": {
"lastModified": 1779560665, "lastModified": 1779560665,
"narHash": "sha256-tpyBcxPpcQb8ukyNF7DoCwfSY3VPsxHoYwj00Cayv5o=", "narHash": "sha256-tpyBcxPpcQb8ukyNF7DoCwfSY3VPsxHoYwj00Cayv5o=",
@ -139,7 +173,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_4": { "nixpkgs_5": {
"locked": { "locked": {
"lastModified": 1727348695, "lastModified": 1727348695,
"narHash": "sha256-J+PeFKSDV+pHL7ukkfpVzCOO7mBSrrpJ3svwBFABbhI=", "narHash": "sha256-J+PeFKSDV+pHL7ukkfpVzCOO7mBSrrpJ3svwBFABbhI=",
@ -162,6 +196,7 @@
"nix-index-database": "nix-index-database", "nix-index-database": "nix-index-database",
"nixos-hardware": "nixos-hardware", "nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_2", "nixpkgs": "nixpkgs_2",
"tourbox-linux": "tourbox-linux",
"yoi": "yoi", "yoi": "yoi",
"zen-browser": "zen-browser" "zen-browser": "zen-browser"
} }
@ -196,17 +231,51 @@
"type": "github" "type": "github"
} }
}, },
"yoi": { "systems_3": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"tourbox-linux": {
"inputs": { "inputs": {
"flake-utils": "flake-utils_2", "flake-utils": "flake-utils_2",
"nixpkgs": "nixpkgs_3" "nixpkgs": "nixpkgs_3"
}, },
"locked": { "locked": {
"lastModified": 1780446170, "lastModified": 1782109395,
"narHash": "sha256-Jfmsj1boCZ1xIZw+7rUN/cib61KKX37lZ0I4T+Ds6SA=", "narHash": "sha256-5b11NT4jgnTrZj8O94MbqiWjslgeKoiqnlfmZ4eJu3s=",
"owner": "HareK02",
"repo": "TourBox-Linux",
"rev": "d5d5055514576701c05d177186bba2ed2f65cc91",
"type": "github"
},
"original": {
"owner": "HareK02",
"repo": "TourBox-Linux",
"type": "github"
}
},
"yoi": {
"inputs": {
"flake-utils": "flake-utils_3",
"nixpkgs": "nixpkgs_4"
},
"locked": {
"lastModified": 1784328575,
"narHash": "sha256-4LdSQBnOPZ82otj2go33qAtDUcVtWFRmMvfgKdQO9Ys=",
"ref": "develop", "ref": "develop",
"rev": "cc98c0eb28376adef8722ec96b8e2ffba05e4f8f", "rev": "37c44a7942776ce43d21f0aa55e55006de1aa6a4",
"revCount": 950, "revCount": 3343,
"type": "git", "type": "git",
"url": "ssh://git@gitea.hareworks.net/Hare/yoi.git" "url": "ssh://git@gitea.hareworks.net/Hare/yoi.git"
}, },
@ -218,7 +287,7 @@
}, },
"zen-browser": { "zen-browser": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_4" "nixpkgs": "nixpkgs_5"
}, },
"locked": { "locked": {
"lastModified": 1761859251, "lastModified": 1761859251,

View File

@ -11,6 +11,7 @@
nixos-hardware.url = "github:NixOS/nixos-hardware"; nixos-hardware.url = "github:NixOS/nixos-hardware";
zen-browser.url = "github:xaragon/zen-browser-flake"; zen-browser.url = "github:xaragon/zen-browser-flake";
yoi.url = "git+ssh://git@gitea.hareworks.net/Hare/yoi.git?ref=develop"; yoi.url = "git+ssh://git@gitea.hareworks.net/Hare/yoi.git?ref=develop";
tourbox-linux.url = "github:HareK02/TourBox-Linux";
nix-index-database.url = "github:Mic92/nix-index-database"; nix-index-database.url = "github:Mic92/nix-index-database";
nix-index-database.inputs.nixpkgs.follows = "nixpkgs"; nix-index-database.inputs.nixpkgs.follows = "nixpkgs";

View File

@ -12,5 +12,8 @@ mkHost {
nixos = ./hare/nixos.nix; nixos = ./hare/nixos.nix;
} }
]; ];
systemModules = [ ./nixos.nix ]; systemModules = [
inputs.tourbox-linux.nixosModules.default
./nixos.nix
];
} }

View File

@ -36,6 +36,14 @@
scale = 1; scale = 1;
transform = 0; transform = 0;
} }
# {
# output = "DP-3";
# mode = "1920x1080@60";
# position = "0x0";
# scale = 0.75;
# transform = 0;
# mirror = "DP-1";
# }
{ {
output = "DP-3"; output = "DP-3";
mode = "1920x1080@144"; mode = "1920x1080@144";
@ -78,7 +86,7 @@
orca-slicer orca-slicer
davinci-resolve davinci-resolve
inputs.zen-browser.packages."${stdenv.hostPlatform.system}".default inputs.zen-browser.packages."${stdenv.hostPlatform.system}".default
inputs.yoi.packages.${stdenv.hostPlatform.system}.default # inputs.yoi.packages.${stdenv.hostPlatform.system}.default
]; ];
services.easyeffects = { services.easyeffects = {
enable = true; enable = true;

View File

@ -90,6 +90,7 @@ in
ATTRS{idVendor}=="414", ATTRS{idProduct}=="211a", MODE="0777" ATTRS{idVendor}=="414", ATTRS{idProduct}=="211a", MODE="0777"
KERNEL=="hidraw*", SUBSYSTEM=="hidraw", MODE="0660", GROUP="input" KERNEL=="hidraw*", SUBSYSTEM=="hidraw", MODE="0660", GROUP="input"
''; '';
services.tourbox-linux.enable = true;
hardware.bluetooth = { hardware.bluetooth = {
enable = true; enable = true;

View File

@ -15,6 +15,8 @@ let
hl.env("HYPRCURSOR_THEME", "rose-pine-hyprcursor") hl.env("HYPRCURSOR_THEME", "rose-pine-hyprcursor")
hl.env("HYPRCURSOR_SIZE", "24") hl.env("HYPRCURSOR_SIZE", "24")
hl.env("XCURSOR_SIZE", "24") hl.env("XCURSOR_SIZE", "24")
hl.env("GTK_USE_PORTAL", "0")
hl.env("GDK_DEBUG", "no-portals")
hl.env("XDG_CURRENT_DESKTOP", "Hyprland") hl.env("XDG_CURRENT_DESKTOP", "Hyprland")
hl.env("XDG_SESSION_TYPE", "wayland") hl.env("XDG_SESSION_TYPE", "wayland")
@ -31,13 +33,14 @@ let
force_default_wallpaper = false, force_default_wallpaper = false,
disable_hyprland_logo = true, disable_hyprland_logo = true,
disable_splash_rendering = true, disable_splash_rendering = true,
disable_hyprland_guiutils_check = true,
}, },
}) })
hl.on("hyprland.start", function() hl.on("hyprland.start", function()
hl.exec_cmd("${ hl.exec_cmd("${
config.programs.regreet.package or pkgs.regreet config.programs.regreet.package or pkgs.regreet
}/bin/regreet; hyprctl dispatch exit") }/bin/regreet; ${pkgs.hyprland}/bin/hyprctl dispatch 'hl.dsp.exit()'")
end) end)
''; '';
in in
@ -51,7 +54,7 @@ in
config = { config = {
services.greetd.enable = true; services.greetd.enable = true;
services.greetd.settings.default_session = { services.greetd.settings.default_session = {
command = "${pkgs.hyprland}/bin/start-hyprland -- -c ${hyprGreetConf}"; command = "${pkgs.dbus}/bin/dbus-run-session ${pkgs.hyprland}/bin/start-hyprland -- -c ${hyprGreetConf}";
user = "greeter"; user = "greeter";
}; };
@ -80,9 +83,6 @@ in
GTK = { GTK = {
application_prefer_dark_theme = true; application_prefer_dark_theme = true;
}; };
background = {
path = "/usr/share/wallpaper/arknights-image-01.png";
};
}; };
}; };
}; };

View File

@ -5,6 +5,7 @@
alsa.enable = true; alsa.enable = true;
alsa.support32Bit = true; alsa.support32Bit = true;
pulse.enable = true; pulse.enable = true;
jack.enable = true;
extraConfig.pipewire."92-low-latency" = { extraConfig.pipewire."92-low-latency" = {
context.properties = { context.properties = {
default.clock.rate = 48000; default.clock.rate = 48000;