diff options
Diffstat (limited to 'nixpkgs/pkgs/tools/nix/nixos-generators/default.nix')
-rw-r--r-- | nixpkgs/pkgs/tools/nix/nixos-generators/default.nix | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/tools/nix/nixos-generators/default.nix b/nixpkgs/pkgs/tools/nix/nixos-generators/default.nix new file mode 100644 index 000000000000..74bbcbd0ae6b --- /dev/null +++ b/nixpkgs/pkgs/tools/nix/nixos-generators/default.nix @@ -0,0 +1,26 @@ +{ stdenv, lib, fetchFromGitHub, makeWrapper, coreutils, jq, findutils, nix }: + +stdenv.mkDerivation rec { + pname = "nixos-generators"; + version = "1.2.0"; + src = fetchFromGitHub { + owner = "nix-community"; + repo = "nixos-generators"; + rev = version; + sha256 = "1iwc39hzvzzyndxwbnl3fck7phxnjpnhy8zn4nyp8is1fiw0648v"; + }; + nativeBuildInputs = [ makeWrapper ]; + installFlags = [ "PREFIX=$(out)" ]; + postFixup = '' + wrapProgram $out/bin/nixos-generate \ + --prefix PATH : ${lib.makeBinPath [ jq coreutils findutils nix ] } + ''; + + meta = with stdenv.lib; { + description = "Collection of image builders"; + homepage = "https://github.com/nix-community/nixos-generators"; + license = licenses.mit; + maintainers = with maintainers; [ lassulus ]; + platforms = platforms.unix; + }; +} |