@@ -235,18 +235,27 @@ export async function runBuild(arg?: TreeNode): Promise<SamBuildResult> {
235235 await updateRecentResponse ( buildMementoRootKey , 'global' , 'templatePath' , templatePath )
236236
237237 try {
238- const { path : samCliPath } = await getSamCliPathAndVersion ( )
238+ await vscode . window . withProgress (
239+ {
240+ location : vscode . ProgressLocation . Notification ,
241+ } ,
242+ async ( progress ) => {
243+ progress . report ( { message : `Building SAM template at ${ params . template . uri . path } ` } )
239244
240- // Create a child process to run the SAM build command
241- const buildProcess = new ChildProcess ( samCliPath , [ 'build' , ...buildFlags ] , {
242- spawnOptions : await addTelemetryEnvVar ( {
243- cwd : params . projectRoot . fsPath ,
244- env : await getSpawnEnv ( process . env ) ,
245- } ) ,
246- } )
245+ const { path : samCliPath } = await getSamCliPathAndVersion ( )
246+
247+ // Create a child process to run the SAM build command
248+ const buildProcess = new ChildProcess ( samCliPath , [ 'build' , ...buildFlags ] , {
249+ spawnOptions : await addTelemetryEnvVar ( {
250+ cwd : params . projectRoot . fsPath ,
251+ env : await getSpawnEnv ( process . env ) ,
252+ } ) ,
253+ } )
247254
248- // Run SAM build in Terminal
249- await runInTerminal ( buildProcess , 'build' )
255+ // Run SAM build in Terminal
256+ await runInTerminal ( buildProcess , 'build' )
257+ }
258+ )
250259
251260 await unregisterTemplateBuild ( params . template . uri . path )
252261
0 commit comments