mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-22 05:33:23 +00:00
48 lines
1.3 KiB
Nix
48 lines
1.3 KiB
Nix
{ stdenvNoCC, lib, fetchFromGitHub, makeWrapper, wget }:
|
||
|
||
stdenvNoCC.mkDerivation rec {
|
||
pname = "distrobox";
|
||
version = "1.4.2.1";
|
||
|
||
src = fetchFromGitHub {
|
||
owner = "89luca89";
|
||
repo = pname;
|
||
rev = version;
|
||
sha256 = "sha256-s3lq1Xr2y29cmyT1nY5/amiDA9dNfyGaMtjTvUINSD8=";
|
||
};
|
||
|
||
dontConfigure = true;
|
||
dontBuild = true;
|
||
|
||
nativeBuildInputs = [ makeWrapper ];
|
||
installPhase = ''
|
||
runHook preInstall
|
||
|
||
# https://github.com/89luca89/distrobox/issues/408
|
||
substituteInPlace ./distrobox-generate-entry \
|
||
--replace 'icon_default="''${HOME}/.local' "icon_default=\"$out"
|
||
./install -P $out
|
||
|
||
runHook postInstall
|
||
'';
|
||
|
||
# https://github.com/89luca89/distrobox/issues/407
|
||
postFixup = ''
|
||
wrapProgram "$out/bin/distrobox-generate-entry" \
|
||
--prefix PATH ":" ${lib.makeBinPath [ wget ]}
|
||
'';
|
||
|
||
meta = with lib; {
|
||
description = "Wrapper around podman or docker to create and start containers";
|
||
longDescription = ''
|
||
Use any linux distribution inside your terminal. Enable both backward and
|
||
forward compatibility with software and freedom to use whatever distribution
|
||
you’re more comfortable with
|
||
'';
|
||
homepage = "https://distrobox.privatedns.org/";
|
||
license = licenses.gpl3Only;
|
||
platforms = platforms.all;
|
||
maintainers = with maintainers; [ atila ];
|
||
};
|
||
}
|