depot/third_party/nixpkgs/pkgs/tools/virtualization/nixos-shell/default.nix
Default email d0d8e8fc71 Project import generated by Copybara.
GitOrigin-RevId: d3f7e969b9860fb80750147aeb56dab1c730e756
2021-03-23 19:22:30 +00:00

30 lines
728 B
Nix

{ lib, stdenv, nix, fetchFromGitHub, makeWrapper }:
stdenv.mkDerivation rec {
pname = "nixos-shell";
version = "0.2.1";
src = fetchFromGitHub {
owner = "Mic92";
repo = "nixos-shell";
rev = version;
sha256 = "sha256-HoY2diusDHXwR0BjYwKR3svLz5LrviE03yxyjWG9oPQ=";
};
nativeBuildInputs = [ makeWrapper ];
postInstall = ''
wrapProgram $out/bin/nixos-shell \
--prefix PATH : ${lib.makeBinPath [ nix ]}
'';
installFlags = [ "PREFIX=${placeholder "out"}" ];
meta = with lib; {
description = "Spawns lightweight nixos vms in a shell";
inherit (src.meta) homepage;
license = licenses.mit;
maintainers = with maintainers; [ mic92 ];
platforms = platforms.unix;
};
}