MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / exportTaskWithId

Method exportTaskWithId

src/core/webview/ClineProvider.ts:1950–1962  ·  view source on GitHub ↗
(id: string)

Source from the content-addressed store, hash-verified

1948 }
1949
1950 async exportTaskWithId(id: string) {
1951 const { historyItem, apiConversationHistory } = await this.getTaskWithId(id)
1952 const fileName = getTaskFileName(historyItem.ts)
1953 const defaultUri = await resolveDefaultSaveUri(this.contextProxy, "lastTaskExportPath", fileName, {
1954 useWorkspace: false,
1955 fallbackDir: path.join(os.homedir(), "Downloads"),
1956 })
1957 const saveUri = await downloadTask(historyItem.ts, apiConversationHistory, defaultUri)
1958
1959 if (saveUri) {
1960 await saveLastExportPath(this.contextProxy, "lastTaskExportPath", saveUri)
1961 }
1962 }
1963
1964 /* Condenses a task's message history to use fewer tokens. */
1965 async condenseTaskContext(taskId: string) {

Callers 1

webviewMessageHandlerFunction · 0.80

Calls 5

getTaskWithIdMethod · 0.95
getTaskFileNameFunction · 0.90
resolveDefaultSaveUriFunction · 0.90
downloadTaskFunction · 0.90
saveLastExportPathFunction · 0.90

Tested by

no test coverage detected