code2prompt: use new cargo fetcher, 1.1.0 -> 4.2.0, modernize (#487812)

This commit is contained in:
Arne Keller
2026-07-01 17:00:20 +00:00
committed by GitHub
2 changed files with 12 additions and 1712 deletions
File diff suppressed because it is too large Load Diff
+12 -13
View File
@@ -4,31 +4,30 @@
rustPlatform,
pkg-config,
openssl,
perl,
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "code2prompt";
version = "1.1.0";
version = "4.2.0";
src = fetchFromGitHub {
owner = "mufeedvh";
repo = "code2prompt";
rev = "v${finalAttrs.version}";
hash = "sha256-KZqh0Vq4Mn56PhUO1JUzVpNBAGOZqUAsj31Cj5K+Lyk=";
tag = "v${finalAttrs.version}";
hash = "sha256-Gh8SsSTZW7QlyyC3SWJ5pOK2x85/GT7+LPJn2Jeczpc=";
};
cargoLock = {
lockFile = ./Cargo.lock;
};
cargoHash = "sha256-t4HpGqojIkw9OBUAYz4ZEaB7XyHQxkFB2HtlkGKbe2s=";
postPatch = ''
# src is missing Cargo.lock
ln -s ${./Cargo.lock} Cargo.lock
'';
nativeBuildInputs = [
pkg-config
perl
];
nativeBuildInputs = [ pkg-config ];
buildInputs = [ openssl ];
buildInputs = [
openssl
];
meta = {
description = "CLI tool that converts your codebase into a single LLM prompt with a source tree, prompt templating, and token counting";