@@ -10,6 +10,7 @@ import { IStringDictionary } from 'vs/base/common/collections';
10
10
import { toErrorMessage } from 'vs/base/common/errorMessage' ;
11
11
import { getErrorMessage } from 'vs/base/common/errors' ;
12
12
import { Emitter } from 'vs/base/common/event' ;
13
+ import { randomPath } from 'vs/base/common/extpath' ;
13
14
import { Disposable } from 'vs/base/common/lifecycle' ;
14
15
import { ResourceSet } from 'vs/base/common/map' ;
15
16
import { Schemas } from 'vs/base/common/network' ;
@@ -414,6 +415,7 @@ export class ExtensionsScanner extends Disposable {
414
415
@IFileService private readonly fileService : IFileService ,
415
416
@IExtensionsScannerService private readonly extensionsScannerService : IExtensionsScannerService ,
416
417
@IExtensionsProfileScannerService private readonly extensionsProfileScannerService : IExtensionsProfileScannerService ,
418
+ @INativeEnvironmentService private readonly environmentService : INativeEnvironmentService ,
417
419
@ILogService private readonly logService : ILogService ,
418
420
) {
419
421
super ( ) ;
@@ -456,7 +458,7 @@ export class ExtensionsScanner extends Disposable {
456
458
457
459
async extractUserExtension ( extensionKey : ExtensionKey , zipPath : string , metadata : Metadata , token : CancellationToken ) : Promise < ILocalExtension > {
458
460
const folderName = extensionKey . toString ( ) ;
459
- const tempPath = path . join ( this . extensionsScannerService . userExtensionsLocation . fsPath , `. ${ generateUuid ( ) } ` ) ;
461
+ const tempPath = randomPath ( this . environmentService . tmpDir . fsPath ) ;
460
462
const extensionPath = path . join ( this . extensionsScannerService . userExtensionsLocation . fsPath , folderName ) ;
461
463
462
464
try {
0 commit comments