]> Git — Sourcephile - julm/julm-nix.git/blob - home-manager/profiles/ghostty.nix
maint/update(git): use settings
[julm/julm-nix.git] / home-manager / profiles / ghostty.nix
1 {
2 pkgs,
3 lib,
4 config,
5 pkgs-unstable,
6 ...
7 }:
8 {
9 home.packages = [
10 pkgs.nerd-fonts.symbols-only
11 #pkgs.nerd-fonts.DejaVuSansMono
12 ];
13 home.sessionVariables = {
14 TERMINAL = lib.mkDefault "ghostty";
15 };
16 xdg.configFile."ghostty/custom.css".source = ghostty/custom.css;
17 programs.ghostty = {
18 enable = true;
19 package = pkgs-unstable.ghostty;
20 # ConfigurationHelper: https://ghostty.zerebos.com
21 settings = {
22 app-notifications = [
23 "no-clipboard-copy"
24 ];
25 # Explanation: workaround io_uring being… slow.
26 # Issue: https://github.com/ghostty-org/ghostty/discussions/3224#discussioncomment-11691632
27 async-backend = "epoll";
28 #command = "tmux";
29 #gtk-single-instance = "detect";
30 background = "#000000";
31 clipboard-read = "allow";
32 clipboard-trim-trailing-spaces = true;
33 clipboard-write = "allow";
34 confirm-close-surface = false;
35 # ligatures are confusing
36 font-feature = [
37 "-calt"
38 "-dalt"
39 "-dlig"
40 ];
41 font-size = lib.mkDefault 9;
42 copy-on-select = true;
43 cursor-style = "bar";
44 cursor-style-blink = true;
45 # Note: home-manager currently does not allow filepaths here, hence use a string.
46 gtk-custom-css = "${config.xdg.configHome}/ghostty/custom.css";
47 gtk-single-instance = "desktop";
48 gtk-titlebar = false;
49 linux-cgroup = "always";
50 linux-cgroup-hard-fail = "true";
51 quit-after-last-window-closed = true;
52 # Keep Ghostty running a bit so that new window creation is faster.
53 quit-after-last-window-closed-delay = "15m";
54 scrollback-limit = "1000000";
55 shell-integration = "detect";
56 shell-integration-features = [
57 "no-cursor"
58 "no-sudo"
59 "no-title"
60 # MaintenanceToDo: enable when ghostty is updated to support it
61 #"ssh-terminfo"
62 #"ssh-env"
63 ];
64 working-directory = "home";
65 };
66 };
67 }