File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
packages/opencode/src/cli/cmd Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -83,6 +83,10 @@ export const RunCommand = cmd({
8383 type : "string" ,
8484 describe : "attach to a running opencode server (e.g., http://localhost:4096)" ,
8585 } )
86+ . option ( "dir" , {
87+ type : "string" ,
88+ describe : "directory to run in (only used with --attach)" ,
89+ } )
8690 . option ( "port" , {
8791 type : "number" ,
8892 describe : "port for the local server (defaults to random port if no value provided)" ,
@@ -276,7 +280,10 @@ export const RunCommand = cmd({
276280 }
277281
278282 if ( args . attach ) {
279- const sdk = createOpencodeClient ( { baseUrl : args . attach } )
283+ const sdk = createOpencodeClient ( {
284+ baseUrl : args . attach ,
285+ directory : args . dir ,
286+ } )
280287
281288 const sessionID = await ( async ( ) => {
282289 if ( args . continue ) {
You can’t perform that action at this time.
0 commit comments