-
-
Notifications
You must be signed in to change notification settings - Fork 31
/
flake.nix
30 lines (27 loc) · 907 Bytes
/
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
{
description = "Easily package your Maven Java application with the Nix package manager";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-21.05";
utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, utils }:
let
# put devShell and any other required packages into local overlay
localOverlay = import ./overlay.nix;
pkgsForSystem = system: import nixpkgs {
overlays = [
localOverlay
];
inherit system;
};
in utils.lib.eachSystem utils.lib.defaultSystems (system: rec {
legacyPackages = pkgsForSystem system;
packages = utils.lib.flattenTree {
inherit (legacyPackages) mvn2nix mvn2nix-bootstrap buildMavenRepository buildMavenRepositoryFromLockFile;
};
defaultPackage = packages.mvn2nix;
apps.mvn2nix = utils.lib.mkApp { drv = packages.mvn2nix; };
}) // {
overlay = localOverlay;
};
}