5cfde22eb7
* Add pandoc support back to rust script * Dont render invalid HTML * Bump schema version * Enable debug build workflow * Dont wrap script * Provide pandoc in check phase * Update Elasticsearch hash * Add _forked_ rust-pandoc * Execute Lua filters * Update nixpkgs containing lua filters * Expose filter path in dev Shell * Dont check pandoc think (for now) * Provide filter path at build time * Enable debug builds * Enable debug builds * rename main.yaml to frontend.yaml * Wrap flake-info with pandoc * Add makeWrapper input * Add pandoc filter path to wrapper * Wrap descriptions in XML frame * Render HTML * Disable import on PR
31 lines
941 B
Nix
31 lines
941 B
Nix
{ pkgs ? import <nixpkgs> { } }: with pkgs;
|
|
rustPlatform.buildRustPackage {
|
|
name = "flake-info";
|
|
src = ./.;
|
|
cargoLock = {
|
|
lockFile = ./Cargo.lock;
|
|
outputHashes = {
|
|
"elasticsearch-8.0.0-alpha.1" = "sha256-gjmk3Q3LTAvLhzQ+k1knSp1HBwtqNiubjXNnLy/cS5M=";
|
|
"pandoc-0.8.6" = "sha256-NsHDzqWjQ17cznjOSpXOdUOhJjAO28Z6QZ6Mn6afVVs=";
|
|
};
|
|
};
|
|
nativeBuildInputs = [ pkg-config ];
|
|
buildInputs = [ openssl openssl.dev makeWrapper ]
|
|
++ lib.optional pkgs.stdenv.isDarwin [ libiconv darwin.apple_sdk.frameworks.Security ];
|
|
|
|
checkInputs = [ pandoc ];
|
|
|
|
NIXPKGS_PANDOC_FILTERS_PATH = "${pkgs.path + "/doc/build-aux/pandoc-filters"}";
|
|
|
|
checkFlags = [
|
|
"--skip elastic::tests"
|
|
"--skip nix_gc::tests"
|
|
];
|
|
|
|
postInstall = ''
|
|
wrapProgram $out/bin/flake-info \
|
|
--set NIXPKGS_PANDOC_FILTERS_PATH "${pkgs.path + "/doc/build-aux/pandoc-filters"}" \
|
|
--prefix PATH : ${pandoc}/bin
|
|
'';
|
|
}
|