diff options
author | Profpatsch <mail@profpatsch.de> | 2022-04-19T13·08+0200 |
---|---|---|
committer | Profpatsch <mail@profpatsch.de> | 2022-04-20T15·12+0000 |
commit | ea871fdcd754828c6d47dfd199a0d9b702d33f19 (patch) | |
tree | 023669ad7bff1a1733651bbbe1fc4399bf55455c /users/Profpatsch | |
parent | 70779f4e651784165449479a70465b9dded41d28 (diff) |
feat(users/Profpatsch/alacritty): Some more configuration r/3980
Change-Id: Ibb2e1892327bd1f27a16dcde1424b8d55c7783d2 Reviewed-on: https://cl.tvl.fyi/c/depot/+/5479 Tested-by: BuildkiteCI Reviewed-by: Profpatsch <mail@profpatsch.de>
Diffstat (limited to '')
-rw-r--r-- | users/Profpatsch/alacritty.dhall | 17 | ||||
-rw-r--r-- | users/Profpatsch/alacritty.nix | 23 |
2 files changed, 28 insertions, 12 deletions
diff --git a/users/Profpatsch/alacritty.dhall b/users/Profpatsch/alacritty.dhall index 5b93a78edad5..b4d99c8294b2 100644 --- a/users/Profpatsch/alacritty.dhall +++ b/users/Profpatsch/alacritty.dhall @@ -1,11 +1,17 @@ let sol = (./solarized.dhall).hex -let solarized-dark = +let black = "#000000" + +let white = "#ffffff" + +let + -- todo: this looks not too good + solarized-dark = { --Colors (Solarized Dark) colors = { -- Default colors primary = - { background = sol.base03, foreground = sol.base0 } + { background = black, foreground = white } , -- Cursor colors cursor = { text = sol.base03, cursor = sol.base0 } @@ -34,4 +40,9 @@ let solarized-dark = } } -in { font.size = 12 } // solarized-dark +in { alacritty-config = { font.size = 18, scolling.history = 100000 } + , -- This disables the dpi-sensitive scaling (cause otherwise the font will be humongous on my laptop screen) + alacritty-env + . WINIT_X11_SCALE_FACTOR + = 1 + } diff --git a/users/Profpatsch/alacritty.nix b/users/Profpatsch/alacritty.nix index 56229c94848b..d2cb8de2fc86 100644 --- a/users/Profpatsch/alacritty.nix +++ b/users/Profpatsch/alacritty.nix @@ -3,8 +3,8 @@ let bins = depot.nix.getBins pkgs.alacritty [ "alacritty" ]; - config = lib.pipe { } [ - (_: depot.users.Profpatsch.importDhall.importDhall { + config = + depot.users.Profpatsch.importDhall.importDhall { root = ./.; files = [ "alacritty.dhall" @@ -12,18 +12,23 @@ let ]; main = "alacritty.dhall"; deps = [ ]; - }) + }; + + config-file = lib.pipe config.alacritty-config [ (lib.generators.toYAML { }) (pkgs.writeText "alacritty.conf") ]; - alacritty = depot.nix.writeExecline "alacritty" { } [ - bins.alacritty - "--config-file" - config - "$@" - ]; + alacritty = depot.nix.writeExecline "alacritty" { } ( + (lib.concatLists (lib.mapAttrsToList (k: v: [ "export" k (toString v) ]) config.alacritty-env)) + ++ [ + bins.alacritty + "--config-file" + config-file + "$@" + ] + ); in alacritty |