add website with docs
This commit is contained in:
parent
870c20e745
commit
fcf1979a1d
12 changed files with 541 additions and 314 deletions
46
flake.nix
46
flake.nix
|
|
@ -3,32 +3,34 @@
|
|||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
deno-with-packages.url = "github:voleum-org/deno-with-packages";
|
||||
deno-with-packages.inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils, deno-with-packages }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
lib = import ./nix // deno-with-packages.lib.${system};
|
||||
shelf = import ./shelf {
|
||||
inherit pkgs system lib;
|
||||
};
|
||||
in
|
||||
{
|
||||
inherit lib;
|
||||
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } {
|
||||
imports = [
|
||||
];
|
||||
systems = [ "x86_64-linux" ];
|
||||
perSystem = { self', pkgs, config, system, ... }: let
|
||||
lib = import ./nix // inputs.deno-with-packages.lib.${system};
|
||||
shelf = import ./shelf {
|
||||
inherit pkgs system lib;
|
||||
};
|
||||
in {
|
||||
packages.website =
|
||||
import ./nix/website.nix { inherit pkgs; root = ./.; };
|
||||
|
||||
devShells.default = pkgs.mkShell {
|
||||
buildInputs = [ pkgs.deno ];
|
||||
shellHook = ''
|
||||
export DENO_DIR=$PWD/.deno_cache
|
||||
${shelf.setupScript}/bin/install-deno-cache
|
||||
devShells.default = pkgs.mkShell {
|
||||
buildInputs = [ pkgs.deno pkgs.pandoc ];
|
||||
shellHook = ''
|
||||
export DENO_DIR=$PWD/.deno_cache
|
||||
${shelf.setupScript}/bin/install-deno-cache
|
||||
|
||||
echo "Availabe scrolls:"
|
||||
echo ${pkgs.lib.escapeShellArg (builtins.toJSON shelf.scrolls)} | jq .
|
||||
'';
|
||||
};
|
||||
});
|
||||
echo "Available scrolls:"
|
||||
echo ${pkgs.lib.escapeShellArg (builtins.toJSON shelf.scrolls)} | jq .
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue