diff --git a/pkgs/by-name/di/distrobox/package.nix b/pkgs/by-name/di/distrobox/package.nix index 8946a7355b9c..dfa17aef48a3 100644 --- a/pkgs/by-name/di/distrobox/package.nix +++ b/pkgs/by-name/di/distrobox/package.nix @@ -4,6 +4,9 @@ fetchFromGitHub, makeWrapper, wget, + gnugrep, + nix-update-script, + testers, }: stdenvNoCC.mkDerivation (finalAttrs: { @@ -13,7 +16,7 @@ stdenvNoCC.mkDerivation (finalAttrs: { src = fetchFromGitHub { owner = "89luca89"; repo = "distrobox"; - rev = finalAttrs.version; + tag = finalAttrs.version; hash = "sha256-uwJD7HsWoQ/LxYL0mSSxMni676qqEnMHndpL01M5ySE="; }; @@ -40,11 +43,21 @@ stdenvNoCC.mkDerivation (finalAttrs: { wrapProgram "$out/bin/distrobox-generate-entry" \ --prefix PATH ":" ${lib.makeBinPath [ wget ]} + wrapProgram "$out/bin/${finalAttrs.meta.mainProgram}" \ + --prefix PATH ":" ${lib.makeBinPath [ gnugrep ]} + mkdir -p $out/share/distrobox echo 'container_additional_volumes="/nix:/nix"' > $out/share/distrobox/distrobox.conf ''; - meta = with lib; { + passthru = { + updateScript = nix-update-script { }; + tests.version = testers.testVersion { + package = finalAttrs.finalPackage; + }; + }; + + meta = { description = "Wrapper around podman or docker to create and start containers"; longDescription = '' Use any linux distribution inside your terminal. Enable both backward and @@ -52,8 +65,9 @@ stdenvNoCC.mkDerivation (finalAttrs: { you’re more comfortable with ''; homepage = "https://distrobox.it/"; - license = licenses.gpl3Only; - platforms = platforms.linux; - maintainers = with maintainers; [ atila ]; + license = lib.licenses.gpl3Only; + platforms = lib.platforms.linux; + maintainers = with lib.maintainers; [ atila ]; + mainProgram = "distrobox"; }; })