{ flake-parts-lib, lib, ... }: { imports = [ ../en-us ]; options.perSystem = flake-parts-lib.mkPerSystemOption ( { config, pkgs, ... }: { options.languages.toml.enable = lib.mkEnableOption "TOML"; config = { editors.helix.languages = { language = [ { name = "toml"; language-servers = [ "taplo" ] ++ (lib.optionals config.languages.en-us.enable [ "harper-ls" "typos" ]); formatter = { command = "${config.treefmt.build.wrapper}/bin/treefmt"; args = [ "--stdin" ".toml" "--quiet" ]; }; auto-format = true; } ]; language-server.taplo.command = "${pkgs.taplo}/bin/taplo"; }; treefmt.programs.taplo.enable = true; pre-commit.settings.hooks.check-toml.enable = true; }; } ); }