From d963c46ec1626f1992a30edc2105502a79ad2099 Mon Sep 17 00:00:00 2001 From: stuebinm Date: Mon, 15 Apr 2024 21:23:07 +0200 Subject: package transport-validator this is the rust tool used by the french ministry for transport (deployed at https://transport.data.gouv.fr/validation), patched to not include the server mode it usually has (i don't want to constantly compile another copy of actix-web) --- pkgs/overlay.nix | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'pkgs/overlay.nix') diff --git a/pkgs/overlay.nix b/pkgs/overlay.nix index f40aac1..4d1d55d 100644 --- a/pkgs/overlay.nix +++ b/pkgs/overlay.nix @@ -75,6 +75,29 @@ in doCheck = false; }; + transport_validator = rustPlatform.buildRustPackage rec { + pname = "transport-validator"; + version = "git"; + src = self.fetchFromGitHub { + owner = "etalab"; + repo = pname; + rev = "f50bee8af83af04805b1b4fcca334152d382c276"; + hash = "sha256-MB66OkSldL0Uy9N0aNOWr293R1Wisu/r0IZNC08m/Ps="; + }; + + # i patch the Cargo.toml to have it optionally not depend on actix + buildNoDefaultFeatures = true; + patches = [ ./patches/transport-validator-without-daemon.patch ]; + + cargoLock.lockFile = "${src}/Cargo.lock"; + # binary name is `main` for some reason + postInstall = '' + mv $out/bin/main $out/bin/transport-validator + ''; + + meta.mainProgram = "transport-validator"; + }; + kijetesantakaluotokieni = self.rustPlatform.buildRustPackage rec { pname = "kijetesantakaluotokieni"; version = "git"; -- cgit v1.2.3