You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: modules/documentation.nix
+12-1Lines changed: 12 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -30,6 +30,12 @@ in
30
30
description="The mkdocs package to use.";
31
31
};
32
32
33
+
mkdocs-preBuildHook=lib.mkOption{
34
+
type=lib.types.lines;
35
+
default="";
36
+
description="script to run in build directory before calling mkdocs. Can be used to prepare .cache directory with Google fonts so mkdocs does not attempt to download them.";
37
+
};
38
+
33
39
strict=lib.mkEnableOption''
34
40
Build the documentation with `--strict`
35
41
@@ -39,8 +45,13 @@ in
39
45
};
40
46
41
47
config=lib.mkIf(cfg.mkdocs-root!=null){
48
+
# some mkdocs plugins want to create a .cache folder.
49
+
# so we link to the project from the build dir.
50
+
# the hook allows the user to prepopulate font files to help avoid mkdocs
0 commit comments