mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-21 09:17:53 +00:00
feat: update code
This commit is contained in:
@@ -91,8 +91,6 @@ export function getCoreSystemPrompt(
|
|||||||
});
|
});
|
||||||
|
|
||||||
if (matchedMapping?.template) {
|
if (matchedMapping?.template) {
|
||||||
const sandbox =
|
|
||||||
process.env.SANDBOX === 'sandbox-exec' ? 'sandbox-exec' : '';
|
|
||||||
const isGitRepo = isGitRepository(process.cwd());
|
const isGitRepo = isGitRepository(process.cwd());
|
||||||
|
|
||||||
// Replace placeholders in template
|
// Replace placeholders in template
|
||||||
@@ -101,7 +99,10 @@ export function getCoreSystemPrompt(
|
|||||||
'{RUNTIME_VARS_IS_GIT_REPO}',
|
'{RUNTIME_VARS_IS_GIT_REPO}',
|
||||||
String(isGitRepo),
|
String(isGitRepo),
|
||||||
);
|
);
|
||||||
template = template.replace('{RUNTIME_VARS_SANDBOX}', sandbox);
|
template = template.replace(
|
||||||
|
'{RUNTIME_VARS_SANDBOX}',
|
||||||
|
process.env.SANDBOX || '',
|
||||||
|
);
|
||||||
|
|
||||||
return template;
|
return template;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user