File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1944,6 +1944,18 @@ it.layer(
19441944 } ) ,
19451945 ) ;
19461946
1947+ it . effect ( "expands a provider home named in any case on Windows" , ( ) =>
1948+ Effect . gen ( function * ( ) {
1949+ const path = yield * Path . Path ;
1950+ const home = yield * HostProcess . HomeDirectory ;
1951+ const { manager, ptyAdapter } = yield * createManager ( 5 ) ;
1952+
1953+ yield * manager . open ( openInput ( { env : { grok_home : "~/.grok-work" } } ) ) ;
1954+
1955+ expect ( ptyAdapter . spawnInputs [ 0 ] ?. env . grok_home ) . toBe ( path . join ( home , ".grok-work" ) ) ;
1956+ } ) . pipe ( Effect . provide ( layerWithHostPlatform ( "win32" ) ) ) ,
1957+ ) ;
1958+
19471959 it . effect ( "fails closed when a provider instance is missing" , ( ) =>
19481960 Effect . gen ( function * ( ) {
19491961 const providerInstanceId = ProviderInstanceId . make ( "deleted_instance" ) ;
Original file line number Diff line number Diff line change @@ -1367,7 +1367,11 @@ function createTerminalSpawnEnv(
13671367 platform === "win32"
13681368 ? Object . keys ( spawnEnv ) . find ( ( candidate ) => candidate . toLowerCase ( ) === key . toLowerCase ( ) )
13691369 : undefined ;
1370- spawnEnv [ existingKey ?? key ] = expandHomeVariable ( key , value , home ) ;
1370+ spawnEnv [ existingKey ?? key ] = expandHomeVariable (
1371+ platform === "win32" ? key . toUpperCase ( ) : key ,
1372+ value ,
1373+ home ,
1374+ ) ;
13711375 }
13721376 }
13731377 if ( ! spawnEnv . COLORTERM && runtimeEnv ?. COLORTERM === undefined ) {
You can’t perform that action at this time.
0 commit comments