treewide: remove use of multiple with statements (#1085)

This commit is contained in:
awwpotato 2025-04-08 15:22:18 -07:00 committed by GitHub
parent a2f8840bed
commit c8bc1c1d9e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 161 additions and 155 deletions

View file

@ -3,11 +3,6 @@
lib,
...
}:
let
theme = config.lib.stylix.colors {
templateRepo = config.stylix.inputs.tinted-zed;
};
in
{
options.stylix.targets.zed.enable = config.lib.stylix.mkEnableTarget "zed" true;
@ -19,14 +14,20 @@ in
&& config.programs.zed-editor.enable
)
{
programs.zed-editor.userSettings = {
"buffer_font_family" = config.stylix.fonts.monospace.name;
"buffer_font_size" = config.stylix.fonts.sizes.terminal * 4.0 / 3.0;
"theme" = "Base16 ${config.lib.stylix.colors.scheme-name}";
"ui_font_family" = config.stylix.fonts.sansSerif.name;
"ui_font_size" = config.stylix.fonts.sizes.applications * 4.0 / 3.0;
};
programs.zed-editor.userSettings =
let
inherit (config.stylix) fonts;
in
{
"buffer_font_family" = fonts.monospace.name;
"buffer_font_size" = fonts.sizes.terminal * 4.0 / 3.0;
"theme" = "Base16 ${config.lib.stylix.colors.scheme-name}";
"ui_font_family" = fonts.sansSerif.name;
"ui_font_size" = fonts.sizes.applications * 4.0 / 3.0;
};
xdg.configFile."zed/themes/nix.json".source = theme;
xdg.configFile."zed/themes/nix.json".source = config.lib.stylix.colors {
templateRepo = config.stylix.inputs.tinted-zed;
};
};
}