Files
Ihar HrachyshkaandWolfgang Walther 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

52 lines
1.1 KiB
Nix

{
lib,
curl,
fetchFromGitHub,
jq,
makeBinaryWrapper,
please-cli,
stdenv,
testers,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "please-cli";
version = "0.4.3";
src = fetchFromGitHub {
owner = "TNG";
repo = "please-cli";
rev = "v${finalAttrs.version}";
hash = "sha256-Kpb36Fm49Cxr3PMlSoUfTNEMNmWFktgEoej1904DmEE=";
};
nativeBuildInputs = [ makeBinaryWrapper ];
installPhase = ''
runHook preInstall
install -Dm555 please.sh "$out/bin/please"
wrapProgram $out/bin/please \
--prefix PATH : ${
lib.makeBinPath [
curl
jq
]
}
runHook postInstall
'';
passthru.tests = testers.testVersion {
package = please-cli;
version = "v${finalAttrs.version}";
};
meta = {
description = "AI helper script to create CLI commands based on GPT prompts";
homepage = "https://github.com/TNG/please-cli";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ _8-bit-fox ];
mainProgram = "please";
platforms = lib.platforms.all;
};
})