Adam C. Stephens
2025-10-30 09:10:33 -04:00
parent 826a47105d
commit 13bfa7557e

View File

@@ -1,32 +1,24 @@
{ {
lib, lib,
buildGo125Module, buildGoModule,
fetchFromGitHub, fetchFromGitHub,
nix-update-script, nix-update-script,
writableTmpDirAsHomeHook, writableTmpDirAsHomeHook,
versionCheckHook, versionCheckHook,
}: }:
buildGo125Module (finalAttrs: { buildGoModule (finalAttrs: {
pname = "crush"; pname = "crush";
version = "0.12.1"; version = "0.13.5";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "charmbracelet"; owner = "charmbracelet";
repo = "crush"; repo = "crush";
tag = "v${finalAttrs.version}"; tag = "v${finalAttrs.version}";
hash = "sha256-uESS76cPJ/sYGbsTpaUKlF8g0y2+LYbF4zd7dAoKWWU="; hash = "sha256-MKX26HptDwlwWvmP+9FDlFJzly5xKA0mNVsbeHi1zhg=";
}; };
vendorHash = "sha256-lqoAPp8EW2tW+QjwCuBgxZDbKT3XMvP3qwx/yES1mx4="; vendorHash = "sha256-OiNmZKg+NN7Aoeao8L72Dvgz0moeaZGQ7KVJdvuWagY=";
# rename TestMain to prevent it from running, as it panics in the sandbox.
postPatch = ''
substituteInPlace internal/llm/provider/openai_test.go \
--replace-fail \
"func TestMain" \
"func DisabledTestMain"
'';
ldflags = [ ldflags = [
"-s" "-s"
@@ -37,6 +29,7 @@ buildGo125Module (finalAttrs: {
let let
# these tests fail in the sandbox # these tests fail in the sandbox
skippedTests = [ skippedTests = [
"TestCoderAgent"
"TestOpenAIClientStreamChoices" "TestOpenAIClientStreamChoices"
"TestGrepWithIgnoreFiles" "TestGrepWithIgnoreFiles"
"TestSearchImplementations" "TestSearchImplementations"