Skip to content

Commit 3b5b340

Browse files
committed
Expose task IDs on the Cline stack
1 parent 677e145 commit 3b5b340

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/core/webview/ClineProvider.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,10 @@ export class ClineProvider implements vscode.WebviewViewProvider {
169169
return this.clineStack.length
170170
}
171171

172+
public getCurrentTaskStack(): string[] {
173+
return this.clineStack.map((cline) => cline.taskId)
174+
}
175+
172176
// remove the current task/cline instance (at the top of the stack), ao this task is finished
173177
// and resume the previous task/cline instance (if it exists)
174178
// this is used when a sub task is finished and the parent task needs to be resumed

src/exports/api.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,4 +79,8 @@ export class API extends EventEmitter<RooCodeEvents> implements RooCodeAPI {
7979
public getMessages(taskId: string) {
8080
return this.history.getMessages(taskId)
8181
}
82+
83+
public getCurrentTaskStack(): string[] {
84+
return this.provider.getCurrentTaskStack()
85+
}
8286
}

0 commit comments

Comments
 (0)