Skip to content
This repository was archived by the owner on Apr 20, 2023. It is now read-only.

Commit 2e3ab7a

Browse files
committed
[feat] hack to enable changing base url; all of this needs a rework
1 parent 9470fa1 commit 2e3ab7a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

flake.nix

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
mkHaskellFlakeModule1 =
8686
{ project
8787
, docsPath ? null
88+
, baseUrl ? "/documentation/"
8889
, toHaddock ? [ ]
8990
}: escapeHatch@{ config, lib, flake-parts-lib, ... }: {
9091
_file = "mlabs-tooling.nix:mkHaskellFlakeModule1";
@@ -144,10 +145,10 @@
144145
touch $out
145146
'';
146147

147-
mkDocumentation = path:
148+
mkDocumentation = baseUrl: path:
148149
let
149150
configFile = (pkgs.formats.yaml { }).generate "emanote-configFile" {
150-
template.baseUrl = "/documentation";
151+
template = { inherit baseUrl; };
151152
};
152153
configDir = pkgs.runCommand "emanote-configDir" { } ''
153154
mkdir -p $out
@@ -166,7 +167,7 @@
166167
_module.args.pkgs = pkgs;
167168

168169
packages = self.lib.mkOpaque (mk "packages" // (if docsPath == null then { } else {
169-
docs = mkDocumentation docsPath;
170+
docs = mkDocumentation baseUrl docsPath;
170171
}) // (if toHaddock == [ ] then { } else {
171172
haddock = inputs.plutus.${system}.plutus.library.combine-haddock {
172173
ghc = hn.compiler.ghc924;

0 commit comments

Comments
 (0)