-
Notifications
You must be signed in to change notification settings - Fork 2
/
flake.nix
49 lines (47 loc) · 1.32 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
{
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
inputs.flake-utils.url = "github:numtide/flake-utils";
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let
package_overlay = import ./overlay/packages.nix;
function_overlay = import ./overlay/functions.nix;
extra_packages = import ./overlay/extra-packages.nix;
pkgs = import nixpkgs { inherit system; overlays = [
package_overlay
function_overlay
extra_packages
]; };
janet2nix = pkgs.mkJanetApplication {
name = "janet2nix";
src = ./.;
withJanetPackages = [
pkgs.janetPackages.spork
pkgs.janetPackages.posix-spawn
pkgs.janetPackages.sh
];
};
in {
overlays = [
package_overlay
function_overlay
extra_packages
];
packages = {
janetPackages = pkgs.janetPackages;
default = janet2nix;
};
devShells.default = pkgs.mkShell {
packages = [
(pkgs.mkJanetTree {
name="janet2nix-dev";
withJanetPackages = [
pkgs.janetPackages.spork
pkgs.janetPackages.posix-spawn
pkgs.janetPackages.sh
];
})
];
};
});
}