docs: add linkcheck
This commit is contained in:
parent
3fcadaf275
commit
ab99be2fa7
3 changed files with 23 additions and 1 deletions
14
dev/docs.nix
14
dev/docs.nix
|
@ -23,5 +23,19 @@
|
|||
cd $files
|
||||
mkdocs build --strict --site-dir $out
|
||||
'';
|
||||
docs-linkcheck = pkgs.testers.lycheeLinkCheck rec {
|
||||
extraConfig = {
|
||||
exclude = [
|
||||
"https://fonts.gstatic.com"
|
||||
"https://monitoring.nix-community.org/alertmanager" # 401 behind auth
|
||||
];
|
||||
include_mail = true;
|
||||
include_verbatim = true;
|
||||
};
|
||||
remap = {
|
||||
"https://nix-community.org" = site;
|
||||
};
|
||||
site = config.packages.docs;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -83,7 +83,7 @@
|
|||
darwinConfigurations // devShells // { inherit (self') formatter; } // nixosConfigurations
|
||||
// pkgs.lib.optionalAttrs (system == "x86_64-linux")
|
||||
{
|
||||
inherit (self'.packages) docs;
|
||||
inherit (self'.packages) docs docs-linkcheck;
|
||||
nixpkgs-update-supervisor-test = pkgs.callPackage ./hosts/build02/supervisor_test.nix { };
|
||||
nixosTests-buildbot = pkgs.nixosTests.buildbot;
|
||||
nixosTests-buildbot-nix-master = inputs'.buildbot-nix.checks.master;
|
||||
|
|
8
tasks.py
8
tasks.py
|
@ -108,6 +108,14 @@ def mkdocs(c: Any) -> None:
|
|||
c.run("nix develop .#mkdocs -c mkdocs serve")
|
||||
|
||||
|
||||
@task
|
||||
def docs_linkcheck(c: Any) -> None:
|
||||
"""
|
||||
Run docs online linkchecker
|
||||
"""
|
||||
c.run("nix run .#docs-linkcheck.online")
|
||||
|
||||
|
||||
def get_hosts(hosts: str) -> List[DeployHost]:
|
||||
if hosts == "":
|
||||
res = subprocess.run(
|
||||
|
|
Loading…
Add table
Reference in a new issue