@codingame/monaco-vscode-files-service-override
Advanced tools
Comparing version 10.1.4 to 11.0.0
{ | ||
"name": "@codingame/monaco-vscode-files-service-override", | ||
"version": "10.1.4", | ||
"version": "11.0.0", | ||
"keywords": [], | ||
@@ -29,4 +29,4 @@ "author": { | ||
"dependencies": { | ||
"vscode": "npm:@codingame/monaco-vscode-api@10.1.4" | ||
"vscode": "npm:@codingame/monaco-vscode-api@11.0.0" | ||
} | ||
} |
@@ -13,9 +13,9 @@ import { Throttler } from 'vscode/vscode/vs/base/common/async'; | ||
const ERR_FILE_NOT_FOUND = createFileSystemProviderError(( localize(740, "File does not exist")), FileSystemProviderErrorCode.FileNotFound); | ||
const ERR_FILE_IS_DIR = createFileSystemProviderError(( localize(741, "File is Directory")), FileSystemProviderErrorCode.FileIsADirectory); | ||
const ERR_FILE_NOT_DIR = createFileSystemProviderError(( localize(742, "File is not a directory")), FileSystemProviderErrorCode.FileNotADirectory); | ||
const ERR_DIR_NOT_EMPTY = createFileSystemProviderError(( localize(743, "Directory is not empty")), FileSystemProviderErrorCode.Unknown); | ||
const ERR_FILE_EXCEEDS_STORAGE_QUOTA = createFileSystemProviderError(( localize(744, "File exceeds available storage quota")), FileSystemProviderErrorCode.FileExceedsStorageQuota); | ||
const ERR_FILE_NOT_FOUND = createFileSystemProviderError(( localize(599, "File does not exist")), FileSystemProviderErrorCode.FileNotFound); | ||
const ERR_FILE_IS_DIR = createFileSystemProviderError(( localize(600, "File is Directory")), FileSystemProviderErrorCode.FileIsADirectory); | ||
const ERR_FILE_NOT_DIR = createFileSystemProviderError(( localize(601, "File is not a directory")), FileSystemProviderErrorCode.FileNotADirectory); | ||
const ERR_DIR_NOT_EMPTY = createFileSystemProviderError(( localize(602, "Directory is not empty")), FileSystemProviderErrorCode.Unknown); | ||
const ERR_FILE_EXCEEDS_STORAGE_QUOTA = createFileSystemProviderError(( localize(603, "File exceeds available storage quota")), FileSystemProviderErrorCode.FileExceedsStorageQuota); | ||
const ERR_UNKNOWN_INTERNAL = (message) => createFileSystemProviderError(( localize( | ||
745, | ||
604, | ||
"Internal error occurred in IndexedDB File System Provider. ({0})", | ||
@@ -22,0 +22,0 @@ message |
@@ -37,3 +37,3 @@ import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js'; | ||
throw ( (new Error(localize( | ||
712, | ||
571, | ||
"Unable to create folder '{0}' that already exists but is not a directory", | ||
@@ -153,3 +153,3 @@ resourceForError(directory) | ||
throw ( (new FileOperationError(localize( | ||
713, | ||
572, | ||
"Unable to resolve filesystem provider with relative file path '{0}'", | ||
@@ -164,3 +164,3 @@ this.resourceForError(resource) | ||
error.message = ( localize( | ||
714, | ||
573, | ||
"ENOPRO: No file system provider found for resource '{0}'", | ||
@@ -198,3 +198,3 @@ (resource.toString()) | ||
throw ( (new FileOperationError(localize( | ||
715, | ||
574, | ||
"Unable to resolve nonexistent file '{0}'", | ||
@@ -310,3 +310,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError(localize( | ||
716, | ||
575, | ||
"Unable to create file '{0}' that already exists when overwrite flag is not set", | ||
@@ -369,3 +369,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError(localize( | ||
717, | ||
576, | ||
"Unable to write file '{0}' ({1})", | ||
@@ -382,3 +382,3 @@ this.resourceForError(resource), | ||
throw ( (new Error(localize( | ||
718, | ||
577, | ||
"Unable to unlock file '{0}' because provider does not support it.", | ||
@@ -392,3 +392,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
719, | ||
578, | ||
"Unable to atomically write file '{0}' because provider does not support it.", | ||
@@ -400,3 +400,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
720, | ||
579, | ||
"Unable to atomically write file '{0}' because provider does not support unbuffered writes.", | ||
@@ -408,3 +408,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
721, | ||
580, | ||
"Unable to unlock file '{0}' because atomic write is enabled.", | ||
@@ -424,3 +424,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError(localize( | ||
722, | ||
581, | ||
"Unable to write file '{0}' that is actually a directory", | ||
@@ -435,3 +435,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError( | ||
localize(723, "File Modified Since"), | ||
localize(582, "File Modified Since"), | ||
3 , | ||
@@ -523,3 +523,3 @@ options | ||
const message = ( localize( | ||
724, | ||
583, | ||
"Unable to read file '{0}' ({1})", | ||
@@ -590,3 +590,3 @@ this.resourceForError(resource), | ||
throw ( (new FileOperationError(localize( | ||
725, | ||
584, | ||
"Unable to read file '{0}' that is actually a directory", | ||
@@ -597,3 +597,3 @@ this.resourceForError(resource) | ||
if (typeof options?.etag === 'string' && options.etag !== ETAG_DISABLED && options.etag === stat.etag) { | ||
throw ( (new NotModifiedSinceFileOperationError(localize(726, "File not modified since"), stat, options))); | ||
throw ( (new NotModifiedSinceFileOperationError(localize(585, "File not modified since"), stat, options))); | ||
} | ||
@@ -606,3 +606,3 @@ this.validateReadFileLimits(resource, stat.size, options); | ||
throw ( (new TooLargeFileOperationError(localize( | ||
727, | ||
586, | ||
"Unable to read file '{0}' that is too large to open", | ||
@@ -729,3 +729,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
728, | ||
587, | ||
"Unable to copy when source '{0}' is same as target '{1}' with different path case on a case insensitive file system", | ||
@@ -738,3 +738,3 @@ this.resourceForError(source), | ||
throw ( (new Error(localize( | ||
729, | ||
588, | ||
"Unable to move/copy when source '{0}' is parent of target '{1}'.", | ||
@@ -750,3 +750,3 @@ this.resourceForError(source), | ||
throw ( (new FileOperationError(localize( | ||
730, | ||
589, | ||
"Unable to move/copy '{0}' because target '{1}' already exists at destination.", | ||
@@ -761,3 +761,3 @@ this.resourceForError(source), | ||
throw ( (new Error(localize( | ||
731, | ||
590, | ||
"Unable to move/copy '{0}' into '{1}' since a file would replace the folder it is contained in.", | ||
@@ -807,3 +807,3 @@ this.resourceForError(source), | ||
throw ( (new Error(localize( | ||
732, | ||
591, | ||
"Unable to delete file '{0}' via trash because provider does not support it.", | ||
@@ -816,3 +816,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
733, | ||
592, | ||
"Unable to delete file '{0}' atomically because provider does not support it.", | ||
@@ -824,3 +824,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
734, | ||
593, | ||
"Unable to atomically delete file '{0}' because using trash is enabled.", | ||
@@ -841,3 +841,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError(localize( | ||
735, | ||
594, | ||
"Unable to delete nonexistent file '{0}'", | ||
@@ -852,3 +852,3 @@ this.resourceForError(resource) | ||
throw ( (new Error(localize( | ||
736, | ||
595, | ||
"Unable to delete non-empty folder '{0}'.", | ||
@@ -1114,3 +1114,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError(localize( | ||
737, | ||
596, | ||
"Unable to modify read-only file '{0}'", | ||
@@ -1125,3 +1125,3 @@ this.resourceForError(resource) | ||
throw ( (new FileOperationError(localize( | ||
737, | ||
596, | ||
"Unable to modify read-only file '{0}'", | ||
@@ -1128,0 +1128,0 @@ this.resourceForError(resource) |
@@ -72,3 +72,3 @@ import { VSBuffer } from 'vscode/vscode/vs/base/common/buffer'; | ||
if (typeof options?.limits?.size === 'number' && totalBytesRead > options.limits.size) { | ||
throw createFileSystemProviderError(localize(4558, "File is too large to open"), FileSystemProviderErrorCode.FileTooLarge); | ||
throw createFileSystemProviderError(localize(3623, "File is too large to open"), FileSystemProviderErrorCode.FileTooLarge); | ||
} | ||
@@ -75,0 +75,0 @@ return true; |
@@ -54,4 +54,4 @@ import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js'; | ||
static { AbstractTextFileService_1 = this; } | ||
static { this.TEXTFILE_SAVE_CREATE_SOURCE = SaveSourceRegistry.registerSource('textFileCreate.source', ( localize(4559, "File Created"))); } | ||
static { this.TEXTFILE_SAVE_REPLACE_SOURCE = SaveSourceRegistry.registerSource('textFileOverwrite.source', ( localize(4560, "File Replaced"))); } | ||
static { this.TEXTFILE_SAVE_CREATE_SOURCE = SaveSourceRegistry.registerSource('textFileCreate.source', ( localize(3624, "File Created"))); } | ||
static { this.TEXTFILE_SAVE_REPLACE_SOURCE = SaveSourceRegistry.registerSource('textFileOverwrite.source', ( localize(3625, "File Replaced"))); } | ||
constructor(fileService, untitledTextEditorService, lifecycleService, instantiationService, modelService, environmentService, dialogService, fileDialogService, textResourceConfigurationService, filesConfigurationService, codeEditorService, pathService, workingCopyFileService, uriIdentityService, languageService, logService, elevatedFileService, decorationsService) { | ||
@@ -86,3 +86,3 @@ super(); | ||
this.files = files; | ||
this.label = ( localize(4561, "Text File Model Decorations")); | ||
this.label = ( localize(3626, "Text File Model Decorations")); | ||
this._onDidChange = this._register(( (new Emitter()))); | ||
@@ -114,3 +114,3 @@ this.onDidChange = this._onDidChange.event; | ||
strikethrough: true, | ||
tooltip: ( localize(4562, "Deleted, Read-only")), | ||
tooltip: ( localize(3627, "Deleted, Read-only")), | ||
}; | ||
@@ -121,3 +121,3 @@ } | ||
letter: Codicon.lockSmall, | ||
tooltip: ( localize(4563, "Read-only")), | ||
tooltip: ( localize(3628, "Read-only")), | ||
}; | ||
@@ -129,3 +129,3 @@ } | ||
strikethrough: true, | ||
tooltip: ( localize(4564, "Deleted")), | ||
tooltip: ( localize(3629, "Deleted")), | ||
}; | ||
@@ -184,3 +184,3 @@ } | ||
throw ( (new TextFileOperationError( | ||
localize(4565, "File seems to be binary and cannot be opened as text"), | ||
localize(3630, "File seems to be binary and cannot be opened as text"), | ||
0 , | ||
@@ -403,3 +403,3 @@ options | ||
message: ( localize( | ||
4566, | ||
3631, | ||
"'{0}' already exists. Do you want to replace it?", | ||
@@ -409,3 +409,3 @@ basename(resource) | ||
detail: ( localize( | ||
4567, | ||
3632, | ||
"A file or folder with the name '{0}' already exists in the folder '{1}'. Replacing it will overwrite its current contents.", | ||
@@ -415,3 +415,3 @@ basename(resource), | ||
)), | ||
primaryButton: ( localize(4568, "&&Replace")), | ||
primaryButton: ( localize(3633, "&&Replace")), | ||
}); | ||
@@ -424,8 +424,8 @@ return confirmed; | ||
message: ( localize( | ||
4569, | ||
3634, | ||
"'{0}' is marked as read-only. Do you want to save anyway?", | ||
basename(resource) | ||
)), | ||
detail: ( localize(4570, "Paths can be configured as read-only via settings.")), | ||
primaryButton: ( localize(4571, "&&Save Anyway")) | ||
detail: ( localize(3635, "Paths can be configured as read-only via settings.")), | ||
primaryButton: ( localize(3636, "&&Save Anyway")) | ||
}); | ||
@@ -432,0 +432,0 @@ return confirmed; |
@@ -64,3 +64,3 @@ import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js'; | ||
notificationService.error(( localize( | ||
9909, | ||
9540, | ||
"Failed to save '{0}': {1}", | ||
@@ -67,0 +67,0 @@ model.name, |
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js'; | ||
import { raceCancellation } from 'vscode/vscode/vs/base/common/async'; | ||
import { CancellationTokenSource } from 'vscode/vscode/vs/base/common/cancellation'; | ||
import { ILogService } from 'vscode/vscode/vs/platform/log/common/log.service'; | ||
import { IProgressService } from 'vscode/vscode/vs/platform/progress/common/progress.service'; | ||
import { Disposable, toDisposable } from 'vscode/vscode/vs/base/common/lifecycle'; | ||
import { insert } from 'vscode/vscode/vs/base/common/arrays'; | ||
import { LinkedList } from 'vscode/vscode/vs/base/common/linkedList'; | ||
import { localize } from 'vscode/vscode/vs/nls'; | ||
import { NotificationPriority } from 'vscode/vscode/vs/platform/notification/common/notification'; | ||
import { isCancellationError, CancellationError } from 'vscode/vscode/vs/base/common/errors'; | ||
let TextFileSaveParticipant = class TextFileSaveParticipant extends Disposable { | ||
constructor(logService) { | ||
constructor(logService, progressService) { | ||
super(); | ||
this.logService = logService; | ||
this.saveParticipants = []; | ||
this.progressService = progressService; | ||
this.saveParticipants = ( (new LinkedList())); | ||
} | ||
addSaveParticipant(participant) { | ||
const remove = insert(this.saveParticipants, participant); | ||
const remove = this.saveParticipants.push(participant); | ||
return toDisposable(() => remove()); | ||
} | ||
async participate(model, context, progress, token) { | ||
const cts = ( (new CancellationTokenSource(token))); | ||
model.textEditorModel?.pushStackElement(); | ||
for (const saveParticipant of this.saveParticipants) { | ||
if (token.isCancellationRequested || !model.textEditorModel ) { | ||
break; | ||
progress.report({ | ||
message: ( localize(11393, "Running Code Actions and Formatters...")) | ||
}); | ||
let bubbleCancel = false; | ||
await this.progressService.withProgress({ | ||
priority: NotificationPriority.URGENT, | ||
location: 15 , | ||
cancellable: ( localize(11394, "Skip")), | ||
delay: model.isDirty() ? 5000 : 3000 | ||
}, async (progress) => { | ||
for (const saveParticipant of this.saveParticipants) { | ||
if (cts.token.isCancellationRequested || !model.textEditorModel ) { | ||
break; | ||
} | ||
try { | ||
const promise = saveParticipant.participate(model, context, progress, cts.token); | ||
await raceCancellation(promise, cts.token); | ||
} | ||
catch (err) { | ||
if (!isCancellationError(err)) { | ||
this.logService.error(err); | ||
} | ||
else if (!cts.token.isCancellationRequested) { | ||
cts.cancel(); | ||
bubbleCancel = true; | ||
} | ||
} | ||
} | ||
try { | ||
const promise = saveParticipant.participate(model, context, progress, token); | ||
await raceCancellation(promise, token); | ||
} | ||
catch (err) { | ||
this.logService.error(err); | ||
} | ||
}, () => { | ||
cts.cancel(); | ||
}); | ||
model.textEditorModel?.pushStackElement(); | ||
cts.dispose(); | ||
if (bubbleCancel) { | ||
throw ( (new CancellationError())); | ||
} | ||
model.textEditorModel?.pushStackElement(); | ||
} | ||
dispose() { | ||
this.saveParticipants.splice(0, this.saveParticipants.length); | ||
this.saveParticipants.clear(); | ||
super.dispose(); | ||
} | ||
}; | ||
TextFileSaveParticipant = ( __decorate([ | ||
( __param(0, ILogService)) | ||
], TextFileSaveParticipant)); | ||
TextFileSaveParticipant = ( (__decorate([ | ||
( (__param(0, ILogService))), | ||
( (__param(1, IProgressService))) | ||
], TextFileSaveParticipant))); | ||
export { TextFileSaveParticipant }; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
163089
3605
+ Added@codingame/monaco-vscode-api@11.0.0(transitive)
+ Added@codingame/monaco-vscode-base-service-override@11.0.0(transitive)
+ Added@codingame/monaco-vscode-chat-comments-extensions-interactive-notebook-search-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-chat-extensions-interactive-notebook-quickaccess-search-terminal-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-chat-extensions-notebook-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-chat-extensions-notebook-task-terminal-testing-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-chat-extensions-notebook-terminal-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-chat-extensions-notebook-terminal-testing-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-comments-extensions-common@11.0.0(transitive)
+ Added@codingame/monaco-vscode-environment-service-override@11.0.0(transitive)
+ Added@codingame/monaco-vscode-extensions-service-override@11.0.0(transitive)
+ Added@codingame/monaco-vscode-host-service-override@11.0.0(transitive)
+ Added@codingame/monaco-vscode-layout-service-override@11.0.0(transitive)
+ Added@codingame/monaco-vscode-quickaccess-service-override@11.0.0(transitive)
+ Added@xterm/addon-clipboard@0.2.0-beta.53(transitive)
+ Added@xterm/addon-image@0.9.0-beta.70(transitive)
+ Added@xterm/addon-search@0.16.0-beta.70(transitive)
+ Added@xterm/addon-serialize@0.14.0-beta.70(transitive)
+ Added@xterm/addon-unicode11@0.9.0-beta.70(transitive)
+ Added@xterm/addon-webgl@0.19.0-beta.70(transitive)
+ Added@xterm/xterm@5.6.0-beta.70(transitive)
+ Addedjs-base64@3.7.7(transitive)
+ Addedjschardet@3.1.4(transitive)
- Removed@codingame/monaco-vscode-api@10.1.4(transitive)
- Removed@codingame/monaco-vscode-base-service-override@10.1.4(transitive)
- Removed@codingame/monaco-vscode-environment-service-override@10.1.4(transitive)
- Removed@codingame/monaco-vscode-extensions-service-override@10.1.4(transitive)
- Removed@codingame/monaco-vscode-host-service-override@10.1.4(transitive)
- Removed@codingame/monaco-vscode-layout-service-override@10.1.4(transitive)
- Removed@codingame/monaco-vscode-quickaccess-service-override@10.1.4(transitive)
- Removedjschardet@3.1.3(transitive)