hydra: build nmigen docs
This commit is contained in:
parent
48af866c61
commit
7a9960df69
@ -2,7 +2,7 @@
|
||||
"web": {
|
||||
"enabled": 1,
|
||||
"hidden": false,
|
||||
"description": "M-Labs website",
|
||||
"description": "Websites",
|
||||
"nixexprinput": "nixScripts",
|
||||
"nixexprpath": "web.nix",
|
||||
"checkinterval": 300,
|
||||
@ -13,7 +13,8 @@
|
||||
"inputs": {
|
||||
"nixpkgs": { "type": "git", "value": "https://github.com/NixOS/nixpkgs.git nixos-22.05", "emailresponsible": false },
|
||||
"nixScripts": { "type": "git", "value": "https://git.m-labs.hk/M-Labs/nix-scripts.git", "emailresponsible": false },
|
||||
"webSrc": { "type": "git", "value": "https://git.m-labs.hk/M-Labs/web2019.git", "emailresponsible": false }
|
||||
"webSrc": { "type": "git", "value": "https://git.m-labs.hk/M-Labs/web2019.git", "emailresponsible": false },
|
||||
"nmigenSrc": { "type": "git", "value": "https://gitlab.com/nmigen/nmigen.git", "emailresponsible": false }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
29
web.nix
29
web.nix
@ -1,7 +1,30 @@
|
||||
let
|
||||
pkgs = import <nixpkgs> {};
|
||||
src = <webSrc>;
|
||||
web-src = <webSrc>;
|
||||
nmigen-src = <nmigenSrc>;
|
||||
in
|
||||
{
|
||||
web = pkgs.runCommand "web" {} "cd ${src}; ${pkgs.zola}/bin/zola build -o $out";
|
||||
rec {
|
||||
web = pkgs.runCommand "web" {} "cd ${web-src}; ${pkgs.zola}/bin/zola build -o $out";
|
||||
sphinxcontrib-platformpicker = pkgs.python3Packages.buildPythonPackage rec {
|
||||
pname = "sphinxcontrib-platformpicker";
|
||||
version = "1.3";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "whitequark";
|
||||
repo = "sphinxcontrib-platformpicker";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-qKhi4QqYhU7CbNSpziFacXc/sWWPSuM3Nc/oWPmBivM=";
|
||||
};
|
||||
propagatedBuildInputs = [ pkgs.python3Packages.sphinx ];
|
||||
};
|
||||
nmigen-docs = pkgs.stdenvNoCC.mkDerivation {
|
||||
name = "nmigen-docs";
|
||||
src = nmigen-src;
|
||||
buildInputs = [ (pkgs.python3.withPackages(ps: [ ps.sphinx ps.sphinx_rtd_theme sphinxcontrib-platformpicker ])) ];
|
||||
phases = [ "buildPhase" ];
|
||||
buildPhase =
|
||||
''
|
||||
export PYTHONPATH=$src
|
||||
sphinx-build -b html $src/docs $out
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user