@@ -149,23 +149,26 @@ export const layer: Layer.Layer<Service, never, HttpClient.HttpClient | AppProce
149149 return `Upgrade failed for ${ method } .`
150150 }
151151
152- const upgradeCurl = Effect . fnUntraced ( function * ( target : string ) {
153- const response = yield * httpOk . execute ( HttpClientRequest . get ( "https://opencode.ai/install" ) )
154- const body = yield * response . text
155- const bodyBytes = new TextEncoder ( ) . encode ( body )
156- const result = yield * appProcess . run (
157- ChildProcess . make ( "bash" , [ ] , {
158- stdin : Stream . make ( bodyBytes ) ,
159- env : { VERSION : target } ,
160- extendEnv : true ,
161- } ) ,
162- )
163- return {
164- code : result . exitCode ,
165- stdout : result . stdout . toString ( "utf8" ) ,
166- stderr : result . stderr . toString ( "utf8" ) ,
167- }
168- } , Effect . mapError ( ( ) => new UpgradeFailedError ( { stderr : upgradeFailure ( "curl" ) } ) ) )
152+ const upgradeCurl = Effect . fnUntraced (
153+ function * ( target : string ) {
154+ const response = yield * httpOk . execute ( HttpClientRequest . get ( "https://opencode.ai/install" ) )
155+ const body = yield * response . text
156+ const bodyBytes = new TextEncoder ( ) . encode ( body )
157+ const result = yield * appProcess . run (
158+ ChildProcess . make ( "bash" , [ ] , {
159+ stdin : Stream . make ( bodyBytes ) ,
160+ env : { VERSION : target } ,
161+ extendEnv : true ,
162+ } ) ,
163+ )
164+ return {
165+ code : result . exitCode ,
166+ stdout : result . stdout . toString ( "utf8" ) ,
167+ stderr : result . stderr . toString ( "utf8" ) ,
168+ }
169+ } ,
170+ Effect . mapError ( ( ) => new UpgradeFailedError ( { stderr : upgradeFailure ( "curl" ) } ) ) ,
171+ )
169172
170173 const result : Interface = {
171174 info : Effect . fn ( "Installation.info" ) ( function * ( ) {
0 commit comments