treewide: switch to ghostty
This commit is contained in:
parent
263376cf4d
commit
c058aca6e7
4 changed files with 60 additions and 3 deletions
|
@ -17,7 +17,7 @@ in {
|
||||||
"$mod, SUPER_L, exec, ${toggle "anyrun" true}"
|
"$mod, SUPER_L, exec, ${toggle "anyrun" true}"
|
||||||
];
|
];
|
||||||
bind = [
|
bind = [
|
||||||
"$mod, Return, exec, ${run "foot"}"
|
"$mod, Return, exec, ${run "ghostty"}"
|
||||||
"$mod, n, exec, ${run "neovide"}"
|
"$mod, n, exec, ${run "neovide"}"
|
||||||
"$mod, w, exec, ${run "firefox"}"
|
"$mod, w, exec, ${run "firefox"}"
|
||||||
", Print, exec, ${runOnce "grimblast"} --notify --cursor copysave output"
|
", Print, exec, ${runOnce "grimblast"} --notify --cursor copysave output"
|
||||||
|
|
|
@ -72,7 +72,7 @@ in {
|
||||||
"fullscreen, initialclass:^(steam_app_)(.*)$"
|
"fullscreen, initialclass:^(steam_app_)(.*)$"
|
||||||
|
|
||||||
# inhibit idle on every fullscreen app except games
|
# inhibit idle on every fullscreen app except games
|
||||||
"idleinhibit always, fullscreen:1,!initialclass:^(steam_app_)(.*)$"
|
"idleinhibit fullscreen,class:.*"
|
||||||
];
|
];
|
||||||
|
|
||||||
render = {
|
render = {
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
{
|
{
|
||||||
imports = [./foot.nix];
|
imports = [
|
||||||
|
./foot.nix
|
||||||
|
./ghostty.nix
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
54
modules/hm/programs/terminal/emulators/ghostty.nix
Normal file
54
modules/hm/programs/terminal/emulators/ghostty.nix
Normal file
|
@ -0,0 +1,54 @@
|
||||||
|
{
|
||||||
|
lib,
|
||||||
|
osConfig,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
inherit (lib) mapAttrs mkIf optionalAttrs removePrefix;
|
||||||
|
styleCfg = osConfig.local.style;
|
||||||
|
|
||||||
|
mkGhosttyTheme = palette: let
|
||||||
|
colors = mapAttrs (_: value: removePrefix "#" value) palette;
|
||||||
|
in {
|
||||||
|
palette = [
|
||||||
|
"0=#${colors.base00}"
|
||||||
|
"1=#${colors.base08}"
|
||||||
|
"2=#${colors.base0B}"
|
||||||
|
"3=#${colors.base0A}"
|
||||||
|
"4=#${colors.base0D}"
|
||||||
|
"5=#${colors.base0E}"
|
||||||
|
"6=#${colors.base0C}"
|
||||||
|
"7=#${colors.base05}"
|
||||||
|
"8=#${colors.base02}"
|
||||||
|
"9=#${colors.base08}"
|
||||||
|
"10=#${colors.base0B}"
|
||||||
|
"11=#${colors.base0A}"
|
||||||
|
"12=#${colors.base0D}"
|
||||||
|
"13=#${colors.base0E}"
|
||||||
|
"14=#${colors.base0C}"
|
||||||
|
"15=#${colors.base07}"
|
||||||
|
"16=#${colors.base09}"
|
||||||
|
"17=#${colors.base0F}"
|
||||||
|
"18=#${colors.base01}"
|
||||||
|
"19=#${colors.base02}"
|
||||||
|
"20=#${colors.base04}"
|
||||||
|
"21=#${colors.base06}"
|
||||||
|
];
|
||||||
|
background = colors.base00;
|
||||||
|
foreground = colors.base05;
|
||||||
|
cursor-color = colors.base06;
|
||||||
|
selection-background = colors.base02;
|
||||||
|
selection-foreground = colors.base05;
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
config = lib.mkIf osConfig.local.profiles.desktop.enable {
|
||||||
|
programs.ghostty = lib.mkMerge [
|
||||||
|
{
|
||||||
|
enable = true;
|
||||||
|
}
|
||||||
|
(optionalAttrs styleCfg.enable {
|
||||||
|
settings.theme = "base16";
|
||||||
|
themes.base16 = mkIf styleCfg.enable (mkGhosttyTheme styleCfg.scheme.palette);
|
||||||
|
})
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue