preserves-tools: init at 1.0.0
This commit is contained in:
parent
a9d8a8ee8b
commit
bc090d1c3f
11
flake.nix
11
flake.nix
|
@ -11,17 +11,16 @@
|
|||
lib = nixpkgs.lib.extend libOverlay;
|
||||
|
||||
overlay = final: prev:
|
||||
with final; {
|
||||
let rust' = (prev.extend rust.overlay).rust-bin.nightly.latest.default;
|
||||
in {
|
||||
lib = prev.lib.extend libOverlay;
|
||||
syndicate-rs = callPackage ./syndicate-rs {
|
||||
rust = let pkgs = prev.extend rust.overlay;
|
||||
in pkgs.rust-bin.nightly.latest.default;
|
||||
};
|
||||
preserves-tools = final.callPackage ./preserves-tools { rust = rust'; };
|
||||
syndicate-rs = final.callPackage ./syndicate-rs { rust = rust'; };
|
||||
};
|
||||
|
||||
packages = forEachSystem (system:
|
||||
let pkgs = nixpkgs.legacyPackages.${system}.extend self.overlay;
|
||||
in with pkgs; { inherit syndicate-rs; });
|
||||
in with pkgs; { inherit preserves-tools syndicate-rs; });
|
||||
|
||||
nixosModules.syndicate-server =
|
||||
# A little hack to apply our overlay to this module only.
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
{ lib, rustPlatform, rust, fetchCrate }:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "preserves-tool";
|
||||
# use the name of the actual utility so that
|
||||
# nix run …#preserves-tools works as expected.
|
||||
|
||||
version = "1.0.0";
|
||||
src = fetchCrate {
|
||||
pname = "preserves-tools"; # name of the crate
|
||||
inherit version;
|
||||
sha256 = "10vy7pmdbxkcwbr1qwqqv1lfi622pk8ncbp1hn5jrddxrv92q4ph";
|
||||
};
|
||||
cargoHash = "sha256-h6ulvjTDTj8/fmzEn1YgZKmze4jwpmGjcSq78hmq2cU=";
|
||||
nativeBuildInputs = [ rust ];
|
||||
|
||||
meta = {
|
||||
description = "Swiss army knife for working with Preserves documents";
|
||||
homepage = "https://preserves.gitlab.io/preserves/doc/preserves-tool.html";
|
||||
maintainers = with lib.maintainers; [ ehmry ];
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue