This commit is contained in:
David Blass
2026-01-09 18:31:01 -05:00
committed by Colin McDonnell
parent 2f3ae3e481
commit c335032c37
12 changed files with 10734 additions and 10641 deletions
+11 -4
View File
@@ -22,7 +22,15 @@ export const opencode = agent({
installDependencies: true,
});
},
run: async ({ payload, apiKey: _apiKey, apiKeys, mcpServers, cliPath, repo }) => {
run: async ({
payload,
apiKey: _apiKey,
apiKeys,
mcpServers,
cliPath,
repo,
effort: _effort,
}) => {
// 1. configure home/config directory
const tempHome = process.env.PULLFROG_TEMP_DIR!;
const configDir = join(tempHome, ".config", "opencode");
@@ -60,10 +68,9 @@ export const opencode = agent({
// add API keys from apiKeys object
for (const [key, value] of Object.entries(apiKeys || {})) {
const upperKey = key.toUpperCase();
env[upperKey] = value;
env[key] = value;
// also set GOOGLE_GENERATIVE_AI_API_KEY for Google provider compatibility
if (upperKey === "GEMINI_API_KEY") {
if (key === "GEMINI_API_KEY") {
env.GOOGLE_GENERATIVE_AI_API_KEY = value;
}
}