2022-06-22 13:50:47 +02:00
|
|
|
{ lib, fzf, makeWrapper, nix-index, stdenvNoCC }:
|
2021-05-13 09:52:50 +02:00
|
|
|
stdenvNoCC.mkDerivation rec {
|
|
|
|
pname = "comma";
|
|
|
|
version = "0.1.0";
|
|
|
|
|
2021-08-31 19:00:29 +02:00
|
|
|
src = ./comma;
|
2021-05-13 09:52:50 +02:00
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
makeWrapper
|
|
|
|
];
|
|
|
|
|
2021-08-31 19:00:46 +02:00
|
|
|
dontUnpack = true;
|
|
|
|
|
2022-06-22 13:50:47 +02:00
|
|
|
dontBuild = true;
|
2021-05-13 09:52:50 +02:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp $src $out/bin/${meta.mainProgram}
|
|
|
|
chmod a+x $out/bin/${meta.mainProgram}
|
|
|
|
'';
|
|
|
|
|
|
|
|
wrapperPath = lib.makeBinPath [
|
|
|
|
fzf
|
|
|
|
nix-index
|
|
|
|
];
|
|
|
|
|
|
|
|
fixupPhase = ''
|
|
|
|
patchShebangs $out/bin/${meta.mainProgram}
|
|
|
|
wrapProgram $out/bin/${meta.mainProgram} --prefix PATH : "${wrapperPath}"
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
mainProgram = ",";
|
|
|
|
description = "A simple script inspired by Shopify's comma, for modern Nix";
|
2023-03-16 21:37:52 +01:00
|
|
|
homepage = "https://git.belanyi.fr/ambroisie/nix-config";
|
2021-05-13 09:52:50 +02:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
platforms = platforms.unix;
|
2021-05-13 10:27:19 +02:00
|
|
|
maintainers = with maintainers; [ ambroisie ];
|
2021-05-13 09:52:50 +02:00
|
|
|
};
|
|
|
|
}
|