@@ -129,14 +129,24 @@ export const convertLinksInActiveFile = async (plugin: LinkConverterPlugin, fina
129129// --> Command Function: Converts All Links in All Files in Vault and Save in Corresponding Files 
130130export  const  convertLinksInVault  =  async  ( plugin : LinkConverterPlugin ,  finalFormat : 'markdown'  |  'wiki' )  =>  { 
131131    let  mdFiles : TFile [ ]  =  plugin . app . vault . getMarkdownFiles ( ) ; 
132-     for  ( let  mdFile  of  mdFiles )  { 
133-         // --> Skip Excalidraw and Kanban Files 
134-         if  ( hasFrontmatter ( plugin . app ,  mdFile . path ,  'excalidraw-plugin' )  ||  hasFrontmatter ( plugin . app ,  mdFile . path ,  'kanban-plugin' ) )  { 
135-             continue ; 
132+     let  notice  =  new  Notice ( 'Starting link conversion in your vault ' ,  0 ) ; 
133+     try  { 
134+         let  totalCount  =  mdFiles . length ; 
135+         let  counter  =  0 ; 
136+         for  ( let  mdFile  of  mdFiles )  { 
137+             counter ++ ; 
138+             notice . setMessage ( `Converting the links in your vault ${ counter }  /${ totalCount }  .` ) ; 
139+             // --> Skip Excalidraw and Kanban Files 
140+             if  ( hasFrontmatter ( plugin . app ,  mdFile . path ,  'excalidraw-plugin' )  ||  hasFrontmatter ( plugin . app ,  mdFile . path ,  'kanban-plugin' ) )  { 
141+                 continue ; 
142+             } 
143+             await  convertLinksAndSaveInSingleFile ( mdFile ,  plugin ,  finalFormat ) ; 
136144        } 
137-         await  convertLinksAndSaveInSingleFile ( mdFile ,  plugin ,  finalFormat ) ; 
145+     }  catch  ( err )  { 
146+         console . log ( err ) ; 
147+     }  finally  { 
148+         notice . hide ( ) ; 
138149    } 
139-     new  Notice ( 'Conversion for all links in your vault finished.' ) ; 
140150} ; 
141151
142152const  hasFrontmatter  =  ( app : App ,  filePath : string ,  keyToCheck : string )  =>  { 
0 commit comments