@@ -362,7 +362,8 @@ export async function projectContext(
362362 } else {
363363 debug ( `projectContext: Found Quarto project in ${ dir } ` ) ;
364364 const temp = createTempContext ( {
365- dir : join ( dir , ".quarto" , "temp" ) ,
365+ dir : join ( dir , ".quarto" ) ,
366+ prefix : "quarto-session-temp" ,
366367 } ) ;
367368 const fileInformationCache = new Map ( ) ;
368369 const result : ProjectContext = {
@@ -410,6 +411,7 @@ export async function projectContext(
410411 cleanup : ( ) => {
411412 cleanupFileInformationCache ( result ) ;
412413 result . diskCache . close ( ) ;
414+ temp . cleanup ( ) ;
413415 } ,
414416 } ;
415417 const { files, engines } = await projectInputFiles (
@@ -433,7 +435,10 @@ export async function projectContext(
433435 dir = originalDir ;
434436 configResolvers . shift ( ) ;
435437 } else if ( force ) {
436- const temp = globalTempContext ( ) ;
438+ const temp = createTempContext ( {
439+ dir : join ( originalDir , ".quarto" ) ,
440+ prefix : "quarto-session-temp" ,
441+ } ) ;
437442 const fileInformationCache = new Map ( ) ;
438443 const context : ProjectContext = {
439444 resolveBrand : async ( fileName ?: string ) =>
@@ -484,6 +489,7 @@ export async function projectContext(
484489 cleanup : ( ) => {
485490 cleanupFileInformationCache ( context ) ;
486491 context . diskCache . close ( ) ;
492+ temp . cleanup ( ) ;
487493 } ,
488494 } ;
489495 if ( Deno . statSync ( path ) . isDirectory ) {
0 commit comments