File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -39,12 +39,16 @@ export async function initializeLuaRocks(): Promise<void> {
3939 luaRocksTreeProvider
4040 ) ;
4141
42- // Check if LuaRocks is installed
4342 const isInstalled = await luaRocksManager . checkLuaRocksInstallation ( ) ;
4443 if ( isInstalled ) {
4544 let workspace = await luaRocksManager . detectLuaRocksWorkspace ( ) ;
4645 if ( workspace ) {
47- vscode . window . showInformationMessage ( `Found ${ workspace . rockspecFiles . length } rockspec file(s) in workspace` ) ;
46+ // 只有在第一次打开工作区时才显示提示
47+ const hasShownMessage = extensionContext . vscodeContext . workspaceState . get ( 'luarocks.rockspecMessageShown' , false ) ;
48+ if ( ! hasShownMessage ) {
49+ vscode . window . showInformationMessage ( `Found ${ workspace . rockspecFiles . length } rockspec file(s) in workspace` ) ;
50+ await extensionContext . vscodeContext . workspaceState . update ( 'luarocks.rockspecMessageShown' , true ) ;
51+ }
4852 }
4953 }
5054}
You can’t perform that action at this time.
0 commit comments