mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-20 04:02:40 +03:00
40 lines
877 B
Nix
40 lines
877 B
Nix
{ lib, bundlerApp, makeWrapper,
|
|
# Optional dependencies, can be null
|
|
epubcheck,
|
|
bundlerUpdateScript
|
|
}:
|
|
|
|
let
|
|
app = bundlerApp {
|
|
pname = "asciidoctor";
|
|
gemdir = ./.;
|
|
|
|
exes = [
|
|
"asciidoctor"
|
|
"asciidoctor-pdf"
|
|
"asciidoctor-epub3"
|
|
"asciidoctor-revealjs"
|
|
];
|
|
|
|
buildInputs = [ makeWrapper ];
|
|
|
|
postBuild = ''
|
|
wrapProgram "$out/bin/asciidoctor-epub3" \
|
|
${lib.optionalString (epubcheck != null) "--set EPUBCHECK ${epubcheck}/bin/epubcheck"}
|
|
'';
|
|
|
|
passthru = {
|
|
updateScript = bundlerUpdateScript "asciidoctor";
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "A faster Asciidoc processor written in Ruby";
|
|
homepage = "https://asciidoctor.org/";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ gpyh nicknovitski ];
|
|
platforms = platforms.unix;
|
|
};
|
|
};
|
|
in
|
|
app
|