generated from nhcarrigan/template
feat: add configurable max output tokens setting
This commit is contained in:
@@ -296,6 +296,11 @@ impl WslBridge {
|
||||
cmd.env("CLAUDE_CODE_DISABLE_1M_CONTEXT", "1");
|
||||
}
|
||||
|
||||
// Set max output tokens if specified
|
||||
if let Some(max_tokens) = options.max_output_tokens {
|
||||
cmd.env("CLAUDE_CODE_MAX_OUTPUT_TOKENS", max_tokens.to_string());
|
||||
}
|
||||
|
||||
cmd
|
||||
} else {
|
||||
// Running on Windows - use wsl with bash login shell to ensure PATH is loaded
|
||||
@@ -343,6 +348,11 @@ impl WslBridge {
|
||||
claude_cmd.push_str("CLAUDE_CODE_DISABLE_1M_CONTEXT=1 ");
|
||||
}
|
||||
|
||||
// Set max output tokens if specified
|
||||
if let Some(max_tokens) = options.max_output_tokens {
|
||||
claude_cmd.push_str(&format!("CLAUDE_CODE_MAX_OUTPUT_TOKENS={} ", max_tokens));
|
||||
}
|
||||
|
||||
claude_cmd.push_str(
|
||||
"claude --output-format stream-json --input-format stream-json --verbose",
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user