File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- import { logger , streams , task } from "@trigger.dev/sdk" ;
1+ import { logger , task } from "@trigger.dev/sdk" ;
22import { mkdirSync } from "fs" ;
33import type { CursorEvent } from "@/lib/cursor-events" ;
44import { spawnCursorAgent } from "../extensions/cursor-cli" ;
5+ import { cursorStream } from "./cursor-stream" ;
56
67export type CursorAgentPayload = {
78 prompt : string ;
@@ -29,7 +30,7 @@ export const cursorAgentTask = task({
2930 { cwd : workspace , env : { CURSOR_API_KEY : process . env . CURSOR_API_KEY } } ,
3031 ) ;
3132
32- const { waitUntilComplete } = streams . pipe ( "cursor-events" , agent . stream ) ;
33+ const { waitUntilComplete } = cursorStream . pipe ( agent . stream ) ;
3334
3435 const { exitCode, stderr } = await agent . waitUntilExit ( ) ;
3536 await waitUntilComplete ( ) ;
Original file line number Diff line number Diff line change 1+ import { streams } from "@trigger.dev/sdk" ;
2+ import type { CursorEvent } from "@/lib/cursor-events" ;
3+
4+ export const cursorStream = streams . define < CursorEvent > ( {
5+ id : "cursor-events" ,
6+ } ) ;
You can’t perform that action at this time.
0 commit comments