MCPcopy Index your code
hub / github.com/anomalyco/opencode / render

Function render

packages/opencode/src/tool/shell/prompt.ts:273–291  ·  view source on GitHub ↗
(name: string, platform: NodeJS.Platform, limits: Limits, defaultTimeoutMs: number)

Source from the content-addressed store, hash-verified

271}
272
273export function render(name: string, platform: NodeJS.Platform, limits: Limits, defaultTimeoutMs: number) {
274 const selected = profile(name, platform, limits, defaultTimeoutMs)
275 return {
276 description: renderPrompt(DESCRIPTION, {
277 intro: selected.intro,
278 os: platform,
279 shell: name,
280 tmp: Global.Path.tmp,
281 workdirSection: selected.workdirSection,
282 commandSection: selected.commandSection,
283 gitCommands: selected.gitCommands,
284 toolName: ShellID.ToolID,
285 gitCommandRestriction: selected.gitCommandRestriction,
286 createPrInstruction: selected.createPrInstruction,
287 createPrExample: selected.createPrExample,
288 }),
289 parameters: parameterSchema(),
290 }
291}
292
293export * as ShellPrompt from "./prompt"

Callers 1

constructorMethod · 0.50

Calls 3

profileFunction · 0.85
renderPromptFunction · 0.85
parameterSchemaFunction · 0.85

Tested by

no test coverage detected