7 rustPlatform.buildRustPackage rec {
11 src = fetchFromGitHub {
15 hash = "sha256-zt4uXkO6Y0Yc1Wt8l5O79oKbgNLrgip40ftD7UfUPwo=";
19 lockFile = ./Cargo.lock;
21 "tree-sitter-bash-0.19.0" = "sha256-a0/KyHV2jUpytsZSHI7tVw8GfYnuqVjfs5KScLZkB0I=";
22 "tree-sitter-facade-0.9.3" = "sha256-M/npshnHJkU70pP3I4WMXp3onlCSWM5mMIqXP45zcUs=";
23 "tree-sitter-json-0.20.0" = "sha256-cyrea0Y13OVGkXbYE0Cwc7nUsDGEZyoQmPAS9wVuHw0=";
24 "tree-sitter-nickel-0.0.1" = "sha256-aYsEx1Y5oDEqSPCUbf1G3J5Y45ULT9OkD+fn6stzrOU=";
25 "tree-sitter-ocaml-0.20.4" = "sha256-j3Hv2qOMxeBNOW+WIgIYzG3zMIFWPQpoHe94b2rT+A8=";
26 "tree-sitter-ocamllex-0.20.2" = "sha256-YhmEE7I7UF83qMuldHqc/fD/no/7YuZd6CaAIaZ1now=";
27 "tree-sitter-query-0.1.0" = "sha256-5N7FT0HTK3xzzhAlk3wBOB9xlEpKSNIfakgFnsxEi18=";
28 "tree-sitter-rust-0.20.4" = "sha256-seWoMuA87ZWCq3mUXopVeDCcTxX/Bh+B4PFLVa0CBQA=";
29 "tree-sitter-toml-0.5.1" = "sha256-5nLNBxFeOGE+gzbwpcrTVnuL1jLUA0ZLBVw2QrOLsDQ=";
30 "web-tree-sitter-sys-1.3.0" = "sha256-9rKB0rt0y9TD/HLRoB9LjEP9nO4kSWR9ylbbOXo2+2M=";
34 cargoBuildFlags = [ "-p" "topiary-cli" ];
35 cargoTestFlags = cargoBuildFlags;
37 env.TOPIARY_LANGUAGE_DIR = "${placeholder "out"}/share/queries";
40 install -Dm444 queries/* -t $out/share/queries
43 passthru.updateScript = nix-update-script { };
46 description = "Uniform formatter for simple languages, as part of the Tree-sitter ecosystem";
47 mainProgram = "topiary";
48 homepage = "https://github.com/tweag/topiary";
49 changelog = "https://github.com/tweag/topiary/blob/${src.rev}/CHANGELOG.md";
50 license = licenses.mit;
51 maintainers = with maintainers; [ figsoda ];