2020-06-18 22:41:01 +00:00
|
|
|
{
|
|
|
|
description = "Code behind search.nixos.org";
|
|
|
|
|
2022-01-25 16:30:21 +00:00
|
|
|
nixConfig = {
|
|
|
|
extra-substituters = [ "https://nixos-search.cachix.org" ];
|
|
|
|
extra-trusted-public-keys = [ "nixos-search.cachix.org-1:1HV3YF8az4fywnH+pAd+CXFEdpTXtv9WpoivPi+H70o=" ];
|
|
|
|
};
|
|
|
|
|
2020-06-18 22:41:01 +00:00
|
|
|
inputs = {
|
|
|
|
nixpkgs = { url = "nixpkgs/nixos-unstable"; };
|
|
|
|
};
|
|
|
|
|
2021-08-26 07:41:39 +00:00
|
|
|
outputs = { self, nixpkgs }:
|
2020-06-18 22:41:01 +00:00
|
|
|
let
|
|
|
|
systems = [ "x86_64-linux" "i686-linux" "x86_64-darwin" "aarch64-linux" ];
|
|
|
|
forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system);
|
2020-08-28 12:25:38 +00:00
|
|
|
mkPackage = path: system:
|
2020-06-18 22:41:01 +00:00
|
|
|
let
|
|
|
|
pkgs = import nixpkgs {
|
|
|
|
inherit system;
|
2021-12-15 01:38:06 +00:00
|
|
|
overlays = [ ];
|
2020-06-18 22:41:01 +00:00
|
|
|
};
|
|
|
|
in
|
2021-12-15 01:38:06 +00:00
|
|
|
import path { inherit pkgs; };
|
2020-08-28 12:25:38 +00:00
|
|
|
packages = system:
|
2020-06-18 22:41:01 +00:00
|
|
|
{
|
2021-12-06 14:01:26 +00:00
|
|
|
flake-info = mkPackage ./flake-info system;
|
2020-08-28 12:25:38 +00:00
|
|
|
frontend = mkPackage ./. system;
|
2020-06-18 22:41:01 +00:00
|
|
|
};
|
2021-08-17 08:55:08 +00:00
|
|
|
|
|
|
|
devShell = system:
|
2021-12-15 01:38:06 +00:00
|
|
|
let
|
|
|
|
packages_inst = (packages system);
|
|
|
|
pkgs = nixpkgs.legacyPackages.${system};
|
2021-12-06 22:50:15 +00:00
|
|
|
in
|
2021-12-15 01:38:06 +00:00
|
|
|
pkgs.mkShell {
|
2021-12-06 22:50:15 +00:00
|
|
|
inputsFrom = builtins.attrValues packages_inst;
|
|
|
|
shellHook = ''
|
2021-12-15 01:38:06 +00:00
|
|
|
export RUST_SRC_PATH="${pkgs.rustPlatform.rustLibSrc}";
|
|
|
|
export NIXPKGS_PANDOC_FILTERS_PATH="${packages_inst.flake-info.NIXPKGS_PANDOC_FILTERS_PATH}";
|
2021-12-06 22:50:15 +00:00
|
|
|
'';
|
2021-08-17 08:55:08 +00:00
|
|
|
};
|
2020-06-18 22:41:01 +00:00
|
|
|
in
|
2021-12-15 01:38:06 +00:00
|
|
|
{
|
2022-03-16 17:49:23 +00:00
|
|
|
defaultPackage = forAllSystems (mkPackage ./flake-info);
|
2021-12-15 01:38:06 +00:00
|
|
|
packages = forAllSystems packages;
|
|
|
|
devShell = forAllSystems devShell;
|
|
|
|
};
|
2020-06-18 22:41:01 +00:00
|
|
|
}
|