@codingame/monaco-vscode-files-service-override 32.0.2 → 33.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/vscode/src/vs/platform/files/browser/indexedDBFileSystemProvider.js +6 -6
- package/vscode/src/vs/platform/files/common/fileService.js +28 -28
- package/vscode/src/vs/platform/files/common/io.js +1 -1
- package/vscode/src/vs/workbench/services/textfile/browser/textFileService.js +13 -13
- package/vscode/src/vs/workbench/services/textfile/common/textFileEditorModelManager.js +1 -1
- package/vscode/src/vs/workbench/services/textfile/common/textFileSaveParticipant.js +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-files-service-override",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "33.0.5",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - files service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-api": "
|
|
18
|
+
"@codingame/monaco-vscode-api": "33.0.5"
|
|
19
19
|
},
|
|
20
20
|
"main": "index.js",
|
|
21
21
|
"module": "index.js",
|
|
@@ -10,13 +10,13 @@ import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
|
10
10
|
import { createFileSystemProviderError, FileSystemProviderErrorCode, FileType, FileSystemProviderCapabilities, FileChangeType } from '@codingame/monaco-vscode-api/vscode/vs/platform/files/common/files';
|
|
11
11
|
import { BroadcastDataChannel } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/broadcast';
|
|
12
12
|
|
|
13
|
-
const ERR_FILE_NOT_FOUND = createFileSystemProviderError(( localize(
|
|
14
|
-
const ERR_FILE_IS_DIR = createFileSystemProviderError(( localize(
|
|
15
|
-
const ERR_FILE_NOT_DIR = createFileSystemProviderError(( localize(
|
|
16
|
-
const ERR_DIR_NOT_EMPTY = createFileSystemProviderError(( localize(
|
|
17
|
-
const ERR_FILE_EXCEEDS_STORAGE_QUOTA = createFileSystemProviderError(( localize(
|
|
13
|
+
const ERR_FILE_NOT_FOUND = createFileSystemProviderError(( localize(1981, "File does not exist")), FileSystemProviderErrorCode.FileNotFound);
|
|
14
|
+
const ERR_FILE_IS_DIR = createFileSystemProviderError(( localize(1982, "File is Directory")), FileSystemProviderErrorCode.FileIsADirectory);
|
|
15
|
+
const ERR_FILE_NOT_DIR = createFileSystemProviderError(( localize(1983, "File is not a directory")), FileSystemProviderErrorCode.FileNotADirectory);
|
|
16
|
+
const ERR_DIR_NOT_EMPTY = createFileSystemProviderError(( localize(1984, "Directory is not empty")), FileSystemProviderErrorCode.Unknown);
|
|
17
|
+
const ERR_FILE_EXCEEDS_STORAGE_QUOTA = createFileSystemProviderError(( localize(1985, "File exceeds available storage quota")), FileSystemProviderErrorCode.FileExceedsStorageQuota);
|
|
18
18
|
const ERR_UNKNOWN_INTERNAL = message => createFileSystemProviderError(( localize(
|
|
19
|
-
|
|
19
|
+
1986,
|
|
20
20
|
"Internal error occurred in IndexedDB File System Provider. ({0})",
|
|
21
21
|
message
|
|
22
22
|
)), FileSystemProviderErrorCode.Unknown);
|
|
@@ -33,7 +33,7 @@ async function mkdirp(providerExtUri, provider, directory) {
|
|
|
33
33
|
const stat = await provider.stat(directory);
|
|
34
34
|
if ((stat.type & FileType.Directory) === 0) {
|
|
35
35
|
throw ( new Error(( localize(
|
|
36
|
-
|
|
36
|
+
1987,
|
|
37
37
|
"Unable to create folder '{0}' that already exists but is not a directory",
|
|
38
38
|
resourceForError(directory)
|
|
39
39
|
))));
|
|
@@ -159,7 +159,7 @@ let FileService = class FileService extends Disposable {
|
|
|
159
159
|
async withProvider(resource) {
|
|
160
160
|
if (!isAbsolutePath(resource)) {
|
|
161
161
|
throw ( new FileOperationError(( localize(
|
|
162
|
-
|
|
162
|
+
1988,
|
|
163
163
|
"Unable to resolve filesystem provider with relative file path '{0}'",
|
|
164
164
|
this.resourceForError(resource)
|
|
165
165
|
)), FileOperationResult.FILE_INVALID_PATH));
|
|
@@ -169,7 +169,7 @@ let FileService = class FileService extends Disposable {
|
|
|
169
169
|
if (!provider) {
|
|
170
170
|
const error = ( new ErrorNoTelemetry());
|
|
171
171
|
error.message = ( localize(
|
|
172
|
-
|
|
172
|
+
1989,
|
|
173
173
|
"ENOPRO: No file system provider found for resource '{0}'",
|
|
174
174
|
(resource.toString())
|
|
175
175
|
));
|
|
@@ -201,7 +201,7 @@ let FileService = class FileService extends Disposable {
|
|
|
201
201
|
} catch (error) {
|
|
202
202
|
if (toFileSystemProviderErrorCode(error) === FileSystemProviderErrorCode.FileNotFound) {
|
|
203
203
|
throw ( new FileOperationError(( localize(
|
|
204
|
-
|
|
204
|
+
1990,
|
|
205
205
|
"Unable to resolve nonexistent file '{0}'",
|
|
206
206
|
this.resourceForError(resource)
|
|
207
207
|
)), FileOperationResult.FILE_NOT_FOUND));
|
|
@@ -355,7 +355,7 @@ let FileService = class FileService extends Disposable {
|
|
|
355
355
|
async doValidateCreateFile(resource, options) {
|
|
356
356
|
if (!options?.overwrite && (await this.exists(resource))) {
|
|
357
357
|
throw ( new FileOperationError(( localize(
|
|
358
|
-
|
|
358
|
+
1991,
|
|
359
359
|
"Unable to create file '{0}' that already exists when overwrite flag is not set",
|
|
360
360
|
this.resourceForError(resource)
|
|
361
361
|
)), FileOperationResult.FILE_MODIFIED_SINCE, options));
|
|
@@ -413,7 +413,7 @@ let FileService = class FileService extends Disposable {
|
|
|
413
413
|
this._onDidRunOperation.fire(( new FileOperationEvent(resource, FileOperation.WRITE)));
|
|
414
414
|
} catch (error) {
|
|
415
415
|
throw ( new FileOperationError(( localize(
|
|
416
|
-
|
|
416
|
+
1992,
|
|
417
417
|
"Unable to write file '{0}' ({1})",
|
|
418
418
|
this.resourceForError(resource),
|
|
419
419
|
(ensureFileSystemProviderError(error).toString())
|
|
@@ -445,14 +445,14 @@ let FileService = class FileService extends Disposable {
|
|
|
445
445
|
const unlock = !!options?.unlock;
|
|
446
446
|
if (unlock && !(provider.capabilities & FileSystemProviderCapabilities.FileWriteUnlock)) {
|
|
447
447
|
throw ( new Error(( localize(
|
|
448
|
-
|
|
448
|
+
1993,
|
|
449
449
|
"Unable to unlock file '{0}' because provider does not support it.",
|
|
450
450
|
this.resourceForError(resource)
|
|
451
451
|
))));
|
|
452
452
|
}
|
|
453
453
|
if (options?.append && !hasFileAppendCapability(provider)) {
|
|
454
454
|
throw ( new FileOperationError(( localize(
|
|
455
|
-
|
|
455
|
+
1994,
|
|
456
456
|
"Filesystem provider for scheme '{0}' does not does not support append",
|
|
457
457
|
this.resourceForError(resource)
|
|
458
458
|
)), FileOperationResult.FILE_PERMISSION_DENIED));
|
|
@@ -461,21 +461,21 @@ let FileService = class FileService extends Disposable {
|
|
|
461
461
|
if (atomic) {
|
|
462
462
|
if (!(provider.capabilities & FileSystemProviderCapabilities.FileAtomicWrite)) {
|
|
463
463
|
throw ( new Error(( localize(
|
|
464
|
-
|
|
464
|
+
1995,
|
|
465
465
|
"Unable to atomically write file '{0}' because provider does not support it.",
|
|
466
466
|
this.resourceForError(resource)
|
|
467
467
|
))));
|
|
468
468
|
}
|
|
469
469
|
if (!(provider.capabilities & FileSystemProviderCapabilities.FileReadWrite)) {
|
|
470
470
|
throw ( new Error(( localize(
|
|
471
|
-
|
|
471
|
+
1996,
|
|
472
472
|
"Unable to atomically write file '{0}' because provider does not support unbuffered writes.",
|
|
473
473
|
this.resourceForError(resource)
|
|
474
474
|
))));
|
|
475
475
|
}
|
|
476
476
|
if (unlock) {
|
|
477
477
|
throw ( new Error(( localize(
|
|
478
|
-
|
|
478
|
+
1997,
|
|
479
479
|
"Unable to unlock file '{0}' because atomic write is enabled.",
|
|
480
480
|
this.resourceForError(resource)
|
|
481
481
|
))));
|
|
@@ -489,7 +489,7 @@ let FileService = class FileService extends Disposable {
|
|
|
489
489
|
}
|
|
490
490
|
if ((stat.type & FileType.Directory) !== 0) {
|
|
491
491
|
throw ( new FileOperationError(( localize(
|
|
492
|
-
|
|
492
|
+
1998,
|
|
493
493
|
"Unable to write file '{0}' that is actually a directory",
|
|
494
494
|
this.resourceForError(resource)
|
|
495
495
|
)), FileOperationResult.FILE_IS_DIRECTORY, options));
|
|
@@ -518,7 +518,7 @@ let FileService = class FileService extends Disposable {
|
|
|
518
518
|
}
|
|
519
519
|
} catch (error) {}
|
|
520
520
|
}
|
|
521
|
-
throw ( new FileOperationError(( localize(
|
|
521
|
+
throw ( new FileOperationError(( localize(1999, "File Modified Since")), FileOperationResult.FILE_MODIFIED_SINCE, options));
|
|
522
522
|
}
|
|
523
523
|
return {
|
|
524
524
|
stat,
|
|
@@ -602,7 +602,7 @@ let FileService = class FileService extends Disposable {
|
|
|
602
602
|
}
|
|
603
603
|
restoreReadError(error, resource, options) {
|
|
604
604
|
const message = ( localize(
|
|
605
|
-
|
|
605
|
+
2000,
|
|
606
606
|
"Unable to read file '{0}' ({1})",
|
|
607
607
|
this.resourceForError(resource),
|
|
608
608
|
(ensureFileSystemProviderError(error).toString())
|
|
@@ -664,13 +664,13 @@ let FileService = class FileService extends Disposable {
|
|
|
664
664
|
});
|
|
665
665
|
if (stat.isDirectory) {
|
|
666
666
|
throw ( new FileOperationError(( localize(
|
|
667
|
-
|
|
667
|
+
2001,
|
|
668
668
|
"Unable to read file '{0}' that is actually a directory",
|
|
669
669
|
this.resourceForError(resource)
|
|
670
670
|
)), FileOperationResult.FILE_IS_DIRECTORY, options));
|
|
671
671
|
}
|
|
672
672
|
if (typeof options?.etag === "string" && options.etag !== ETAG_DISABLED && options.etag === stat.etag) {
|
|
673
|
-
throw ( new NotModifiedSinceFileOperationError(( localize(
|
|
673
|
+
throw ( new NotModifiedSinceFileOperationError(( localize(2002, "File not modified since")), stat, options));
|
|
674
674
|
}
|
|
675
675
|
this.validateReadFileLimits(resource, stat.size, options);
|
|
676
676
|
return stat;
|
|
@@ -678,7 +678,7 @@ let FileService = class FileService extends Disposable {
|
|
|
678
678
|
validateReadFileLimits(resource, size, options) {
|
|
679
679
|
if (typeof options?.limits?.size === "number" && size > options.limits.size) {
|
|
680
680
|
throw ( new TooLargeFileOperationError(( localize(
|
|
681
|
-
|
|
681
|
+
2003,
|
|
682
682
|
"Unable to read file '{0}' that is too large to open",
|
|
683
683
|
this.resourceForError(resource)
|
|
684
684
|
)), FileOperationResult.FILE_TOO_LARGE, size, options));
|
|
@@ -823,7 +823,7 @@ let FileService = class FileService extends Disposable {
|
|
|
823
823
|
}
|
|
824
824
|
if (isSameResourceWithDifferentPathCase && mode === "copy") {
|
|
825
825
|
throw ( new Error(( localize(
|
|
826
|
-
|
|
826
|
+
2004,
|
|
827
827
|
"Unable to copy when source '{0}' is same as target '{1}' with different path case on a case insensitive file system",
|
|
828
828
|
this.resourceForError(source),
|
|
829
829
|
this.resourceForError(target)
|
|
@@ -831,7 +831,7 @@ let FileService = class FileService extends Disposable {
|
|
|
831
831
|
}
|
|
832
832
|
if (!isSameResourceWithDifferentPathCase && providerExtUri.isEqualOrParent(target, source)) {
|
|
833
833
|
throw ( new Error(( localize(
|
|
834
|
-
|
|
834
|
+
2005,
|
|
835
835
|
"Unable to move/copy when source '{0}' is parent of target '{1}'.",
|
|
836
836
|
this.resourceForError(source),
|
|
837
837
|
this.resourceForError(target)
|
|
@@ -842,7 +842,7 @@ let FileService = class FileService extends Disposable {
|
|
|
842
842
|
if (exists && !isSameResourceWithDifferentPathCase) {
|
|
843
843
|
if (!overwrite) {
|
|
844
844
|
throw ( new FileOperationError(( localize(
|
|
845
|
-
|
|
845
|
+
2006,
|
|
846
846
|
"Unable to move/copy '{0}' because target '{1}' already exists at destination.",
|
|
847
847
|
this.resourceForError(source),
|
|
848
848
|
this.resourceForError(target)
|
|
@@ -854,7 +854,7 @@ let FileService = class FileService extends Disposable {
|
|
|
854
854
|
} = this.getExtUri(sourceProvider);
|
|
855
855
|
if (providerExtUri.isEqualOrParent(source, target)) {
|
|
856
856
|
throw ( new Error(( localize(
|
|
857
|
-
|
|
857
|
+
2007,
|
|
858
858
|
"Unable to move/copy '{0}' into '{1}' since a file would replace the folder it is contained in.",
|
|
859
859
|
this.resourceForError(source),
|
|
860
860
|
this.resourceForError(target)
|
|
@@ -905,7 +905,7 @@ let FileService = class FileService extends Disposable {
|
|
|
905
905
|
const useTrash = !!options?.useTrash;
|
|
906
906
|
if (useTrash && !(provider.capabilities & FileSystemProviderCapabilities.Trash)) {
|
|
907
907
|
throw ( new Error(( localize(
|
|
908
|
-
|
|
908
|
+
2008,
|
|
909
909
|
"Unable to delete file '{0}' via trash because provider does not support it.",
|
|
910
910
|
this.resourceForError(resource)
|
|
911
911
|
))));
|
|
@@ -913,14 +913,14 @@ let FileService = class FileService extends Disposable {
|
|
|
913
913
|
const atomic = options?.atomic;
|
|
914
914
|
if (atomic && !(provider.capabilities & FileSystemProviderCapabilities.FileAtomicDelete)) {
|
|
915
915
|
throw ( new Error(( localize(
|
|
916
|
-
|
|
916
|
+
2009,
|
|
917
917
|
"Unable to delete file '{0}' atomically because provider does not support it.",
|
|
918
918
|
this.resourceForError(resource)
|
|
919
919
|
))));
|
|
920
920
|
}
|
|
921
921
|
if (useTrash && atomic) {
|
|
922
922
|
throw ( new Error(( localize(
|
|
923
|
-
|
|
923
|
+
2010,
|
|
924
924
|
"Unable to atomically delete file '{0}' because using trash is enabled.",
|
|
925
925
|
this.resourceForError(resource)
|
|
926
926
|
))));
|
|
@@ -933,7 +933,7 @@ let FileService = class FileService extends Disposable {
|
|
|
933
933
|
this.throwIfFileIsReadonly(resource, stat);
|
|
934
934
|
} else {
|
|
935
935
|
throw ( new FileOperationError(( localize(
|
|
936
|
-
|
|
936
|
+
2011,
|
|
937
937
|
"Unable to delete nonexistent file '{0}'",
|
|
938
938
|
this.resourceForError(resource)
|
|
939
939
|
)), FileOperationResult.FILE_NOT_FOUND));
|
|
@@ -943,7 +943,7 @@ let FileService = class FileService extends Disposable {
|
|
|
943
943
|
const stat = await this.resolve(resource);
|
|
944
944
|
if (stat.isDirectory && Array.isArray(stat.children) && stat.children.length > 0) {
|
|
945
945
|
throw ( new Error(( localize(
|
|
946
|
-
|
|
946
|
+
2012,
|
|
947
947
|
"Unable to delete non-empty folder '{0}'.",
|
|
948
948
|
this.resourceForError(resource)
|
|
949
949
|
))));
|
|
@@ -1276,7 +1276,7 @@ let FileService = class FileService extends Disposable {
|
|
|
1276
1276
|
throwIfFileSystemIsReadonly(provider, resource) {
|
|
1277
1277
|
if (provider.capabilities & FileSystemProviderCapabilities.Readonly) {
|
|
1278
1278
|
throw ( new FileOperationError(( localize(
|
|
1279
|
-
|
|
1279
|
+
2013,
|
|
1280
1280
|
"Unable to modify read-only file '{0}'",
|
|
1281
1281
|
this.resourceForError(resource)
|
|
1282
1282
|
)), FileOperationResult.FILE_PERMISSION_DENIED));
|
|
@@ -1286,7 +1286,7 @@ let FileService = class FileService extends Disposable {
|
|
|
1286
1286
|
throwIfFileIsReadonly(resource, stat) {
|
|
1287
1287
|
if ((stat.permissions ?? 0) & FilePermission.Readonly) {
|
|
1288
1288
|
throw ( new FileOperationError(( localize(
|
|
1289
|
-
|
|
1289
|
+
2013,
|
|
1290
1290
|
"Unable to modify read-only file '{0}'",
|
|
1291
1291
|
this.resourceForError(resource)
|
|
1292
1292
|
)), FileOperationResult.FILE_PERMISSION_DENIED));
|
|
@@ -80,7 +80,7 @@ function throwIfCancelled(token) {
|
|
|
80
80
|
}
|
|
81
81
|
function throwIfTooLarge(totalBytesRead, options) {
|
|
82
82
|
if (typeof options?.limits?.size === "number" && totalBytesRead > options.limits.size) {
|
|
83
|
-
throw createFileSystemProviderError(( localize(
|
|
83
|
+
throw createFileSystemProviderError(( localize(2020, "File is too large to open")), FileSystemProviderErrorCode.FileTooLarge);
|
|
84
84
|
}
|
|
85
85
|
return true;
|
|
86
86
|
}
|
|
@@ -56,10 +56,10 @@ let AbstractTextFileService = class AbstractTextFileService extends Disposable {
|
|
|
56
56
|
AbstractTextFileService_1 = this;
|
|
57
57
|
}
|
|
58
58
|
static {
|
|
59
|
-
this.TEXTFILE_SAVE_CREATE_SOURCE = SaveSourceRegistry.registerSource("textFileCreate.source", ( localize(
|
|
59
|
+
this.TEXTFILE_SAVE_CREATE_SOURCE = SaveSourceRegistry.registerSource("textFileCreate.source", ( localize(17070, "File Created")));
|
|
60
60
|
}
|
|
61
61
|
static {
|
|
62
|
-
this.TEXTFILE_SAVE_REPLACE_SOURCE = SaveSourceRegistry.registerSource("textFileOverwrite.source", ( localize(
|
|
62
|
+
this.TEXTFILE_SAVE_REPLACE_SOURCE = SaveSourceRegistry.registerSource("textFileOverwrite.source", ( localize(17071, "File Replaced")));
|
|
63
63
|
}
|
|
64
64
|
constructor(
|
|
65
65
|
fileService,
|
|
@@ -108,7 +108,7 @@ let AbstractTextFileService = class AbstractTextFileService extends Disposable {
|
|
|
108
108
|
constructor(files) {
|
|
109
109
|
super();
|
|
110
110
|
this.files = files;
|
|
111
|
-
this.label = ( localize(
|
|
111
|
+
this.label = ( localize(17072, "Text File Model Decorations"));
|
|
112
112
|
this._onDidChange = this._register(( new Emitter()));
|
|
113
113
|
this.onDidChange = this._onDidChange.event;
|
|
114
114
|
this.registerListeners();
|
|
@@ -143,20 +143,20 @@ let AbstractTextFileService = class AbstractTextFileService extends Disposable {
|
|
|
143
143
|
color: listErrorForeground,
|
|
144
144
|
letter: Codicon.lockSmall,
|
|
145
145
|
strikethrough: true,
|
|
146
|
-
tooltip: ( localize(
|
|
146
|
+
tooltip: ( localize(17073, "Deleted, Read-only"))
|
|
147
147
|
};
|
|
148
148
|
}
|
|
149
149
|
else if (isReadonly) {
|
|
150
150
|
return {
|
|
151
151
|
letter: Codicon.lockSmall,
|
|
152
|
-
tooltip: ( localize(
|
|
152
|
+
tooltip: ( localize(17074, "Read-only"))
|
|
153
153
|
};
|
|
154
154
|
}
|
|
155
155
|
else if (isOrphaned) {
|
|
156
156
|
return {
|
|
157
157
|
color: listErrorForeground,
|
|
158
158
|
strikethrough: true,
|
|
159
|
-
tooltip: ( localize(
|
|
159
|
+
tooltip: ( localize(17075, "Deleted"))
|
|
160
160
|
};
|
|
161
161
|
}
|
|
162
162
|
return undefined;
|
|
@@ -207,7 +207,7 @@ let AbstractTextFileService = class AbstractTextFileService extends Disposable {
|
|
|
207
207
|
} catch (error) {
|
|
208
208
|
cts.dispose(true);
|
|
209
209
|
if (error.decodeStreamErrorKind === DecodeStreamErrorKind.STREAM_IS_BINARY) {
|
|
210
|
-
throw ( new TextFileOperationError(( localize(
|
|
210
|
+
throw ( new TextFileOperationError(( localize(17076, "File seems to be binary and cannot be opened as text")), TextFileOperationResult.FILE_IS_BINARY, options));
|
|
211
211
|
}
|
|
212
212
|
else {
|
|
213
213
|
throw error;
|
|
@@ -481,17 +481,17 @@ let AbstractTextFileService = class AbstractTextFileService extends Disposable {
|
|
|
481
481
|
} = await this.dialogService.confirm({
|
|
482
482
|
type: "warning",
|
|
483
483
|
message: ( localize(
|
|
484
|
-
|
|
484
|
+
17077,
|
|
485
485
|
"'{0}' already exists. Do you want to replace it?",
|
|
486
486
|
basename(resource)
|
|
487
487
|
)),
|
|
488
488
|
detail: ( localize(
|
|
489
|
-
|
|
489
|
+
17078,
|
|
490
490
|
"A file or folder with the name '{0}' already exists in the folder '{1}'. Replacing it will overwrite its current contents.",
|
|
491
491
|
basename(resource),
|
|
492
492
|
basename(dirname(resource))
|
|
493
493
|
)),
|
|
494
|
-
primaryButton: ( localize(
|
|
494
|
+
primaryButton: ( localize(17079, "&&Replace"))
|
|
495
495
|
});
|
|
496
496
|
return confirmed;
|
|
497
497
|
}
|
|
@@ -501,12 +501,12 @@ let AbstractTextFileService = class AbstractTextFileService extends Disposable {
|
|
|
501
501
|
} = await this.dialogService.confirm({
|
|
502
502
|
type: "warning",
|
|
503
503
|
message: ( localize(
|
|
504
|
-
|
|
504
|
+
17080,
|
|
505
505
|
"'{0}' is marked as read-only. Do you want to save anyway?",
|
|
506
506
|
basename(resource)
|
|
507
507
|
)),
|
|
508
|
-
detail: ( localize(
|
|
509
|
-
primaryButton: ( localize(
|
|
508
|
+
detail: ( localize(17081, "Paths can be configured as read-only via settings.")),
|
|
509
|
+
primaryButton: ( localize(17082, "&&Save Anyway"))
|
|
510
510
|
});
|
|
511
511
|
return confirmed;
|
|
512
512
|
}
|
|
@@ -70,7 +70,7 @@ let TextFileEditorModelManager = class TextFileEditorModelManager extends Dispos
|
|
|
70
70
|
return {
|
|
71
71
|
onSaveError(error, model) {
|
|
72
72
|
notificationService.error(( localize(
|
|
73
|
-
|
|
73
|
+
17086,
|
|
74
74
|
"Failed to save '{0}': {1}",
|
|
75
75
|
model.name,
|
|
76
76
|
toErrorMessage(error, false)
|
|
@@ -26,13 +26,13 @@ let TextFileSaveParticipant = class TextFileSaveParticipant extends Disposable {
|
|
|
26
26
|
const cts = ( new CancellationTokenSource(token));
|
|
27
27
|
model.textEditorModel?.pushStackElement();
|
|
28
28
|
progress.report({
|
|
29
|
-
message: ( localize(
|
|
29
|
+
message: ( localize(17087, "Running Code Actions and Formatters..."))
|
|
30
30
|
});
|
|
31
31
|
let bubbleCancel = false;
|
|
32
32
|
await this.progressService.withProgress({
|
|
33
33
|
priority: NotificationPriority.URGENT,
|
|
34
34
|
location: ProgressLocation.Notification,
|
|
35
|
-
cancellable: ( localize(
|
|
35
|
+
cancellable: ( localize(17088, "Skip")),
|
|
36
36
|
delay: model.isDirty() ? 5000 : 3000
|
|
37
37
|
}, async progress => {
|
|
38
38
|
const participants = Array.from(this.saveParticipants).sort((a, b) => {
|