summaryrefslogtreecommitdiffstats
path: root/pkgs/tools/typesetting
diff options
context:
space:
mode:
authorzimbatm <zimbatm@zimbatm.com>2019-07-04 18:09:15 +0200
committerzimbatm <zimbatm@zimbatm.com>2019-07-04 18:09:15 +0200
commitf726160556e74c8203f3f8dff0aa0dec07c0218c (patch)
tree2583b676f5c9ecf40c1a463f4d4d1f7c117e708f /pkgs/tools/typesetting
parentd6b7b2a8cfa0803091a4689fa4d307c538ce6bf9 (diff)
asciidoctor: fix update.sh
Diffstat (limited to 'pkgs/tools/typesetting')
-rw-r--r--pkgs/tools/typesetting/asciidoctor/default.nix23
1 files changed, 14 insertions, 9 deletions
diff --git a/pkgs/tools/typesetting/asciidoctor/default.nix b/pkgs/tools/typesetting/asciidoctor/default.nix
index 16ab64db257f..2f1c7e461545 100644
--- a/pkgs/tools/typesetting/asciidoctor/default.nix
+++ b/pkgs/tools/typesetting/asciidoctor/default.nix
@@ -1,11 +1,12 @@
-{ lib, bundlerApp, makeWrapper,
+{ lib, bundlerApp, makeWrapper,
# Optional dependencies, can be null
- epubcheck, kindlegen,
+ epubcheck, kindlegen,
# For the update shell
- mkShell, bundix
+ mkShell, bundix
}:
-let app = bundlerApp {
+let
+ app = bundlerApp {
pname = "asciidoctor";
gemdir = ./.;
@@ -24,6 +25,10 @@ let app = bundlerApp {
${lib.optionalString (kindlegen != null) "--set KINDLEGEN ${kindlegen}/bin/kindlegen"}
'';
+ passthru = {
+ inherit updateShell;
+ };
+
meta = with lib; {
description = "A faster Asciidoc processor written in Ruby";
homepage = https://asciidoctor.org/;
@@ -33,9 +38,9 @@ let app = bundlerApp {
};
};
- # Can't be defined directly in the passthru, since app.gems isn't defined at that point.
- shell = mkShell {
- inputsFrom = lib.mapAttrs app.gems;
- buildInputs = [ bundix ];
+ updateShell = mkShell {
+ inputsFrom = lib.attrValues app.gems;
+ buildInputs = [ bundix ];
};
-in app.overrideAttrs (attrs: { passthru = attrs.passthru // { updateShell = shell; }; })
+in
+ app