@codingame/monaco-vscode-task-service-override 27.0.0 → 28.0.1
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/workbench/contrib/tasks/browser/abstractTaskService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/tasks/browser/abstractTaskService.js +114 -114
- package/vscode/src/vs/workbench/contrib/tasks/browser/runAutomaticTasks.js +7 -7
- package/vscode/src/vs/workbench/contrib/tasks/browser/task.contribution.js +48 -48
- package/vscode/src/vs/workbench/contrib/tasks/browser/taskQuickPick.js +17 -17
- package/vscode/src/vs/workbench/contrib/tasks/browser/taskService.js +1 -1
- package/vscode/src/vs/workbench/contrib/tasks/browser/taskTerminalStatus.js +10 -10
- package/vscode/src/vs/workbench/contrib/tasks/browser/tasksQuickAccess.js +2 -2
- package/vscode/src/vs/workbench/contrib/tasks/browser/terminalTaskSystem.js +17 -17
- package/vscode/src/vs/workbench/contrib/tasks/common/jsonSchemaCommon.js +42 -42
- package/vscode/src/vs/workbench/contrib/tasks/common/jsonSchema_v1.js +9 -9
- package/vscode/src/vs/workbench/contrib/tasks/common/jsonSchema_v2.js +84 -84
- package/vscode/src/vs/workbench/contrib/tasks/common/problemCollectors.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/tasks/common/problemCollectors.js +1 -1
- package/vscode/src/vs/workbench/contrib/tasks/common/taskTemplates.js +4 -4
- package/vscode/src/vs/base/common/parsers.d.ts +0 -32
- package/vscode/src/vs/base/common/parsers.js +0 -54
- package/vscode/src/vs/workbench/contrib/tasks/common/problemMatcher.d.ts +0 -433
- package/vscode/src/vs/workbench/contrib/tasks/common/problemMatcher.js +0 -1637
- package/vscode/src/vs/workbench/contrib/tasks/common/taskConfiguration.d.ts +0 -514
- package/vscode/src/vs/workbench/contrib/tasks/common/taskConfiguration.js +0 -1796
|
@@ -7,7 +7,7 @@ import { parse as parse$1 } from '@codingame/monaco-vscode-api/vscode/vs/base/co
|
|
|
7
7
|
import { Disposable, MutableDisposable, toDisposable, dispose } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
8
8
|
import { LRUCache, Touch } from '@codingame/monaco-vscode-api/vscode/vs/base/common/map';
|
|
9
9
|
import { deepClone } from '@codingame/monaco-vscode-api/vscode/vs/base/common/objects';
|
|
10
|
-
import { ValidationStatus, ValidationState } from '
|
|
10
|
+
import { ValidationStatus, ValidationState } from '@codingame/monaco-vscode-api/vscode/vs/base/common/parsers';
|
|
11
11
|
import { isWeb, Platform, platform } from '@codingame/monaco-vscode-api/vscode/vs/base/common/platform';
|
|
12
12
|
import { TerminateResponseCode } from '@codingame/monaco-vscode-api/vscode/vs/base/common/processes';
|
|
13
13
|
import { basename, joinPath, dirname, relativePath } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
|
|
@@ -28,7 +28,7 @@ import { StorageScope, StorageTarget } from '@codingame/monaco-vscode-api/vscode
|
|
|
28
28
|
import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
|
|
29
29
|
import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service';
|
|
30
30
|
import { IExtensionService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service';
|
|
31
|
-
import { ProblemMatcherRegistry } from '
|
|
31
|
+
import { ProblemMatcherRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/tasks/common/problemMatcher';
|
|
32
32
|
import { IDialogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service';
|
|
33
33
|
import { INotificationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/notification/common/notification.service';
|
|
34
34
|
import { IOpenerService } from '@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service';
|
|
@@ -47,7 +47,7 @@ import { ChatAgentLocation, ChatModeKind } from '@codingame/monaco-vscode-api/vs
|
|
|
47
47
|
import { TasksAvailableContext, TaskCommandsRegistered, ServerlessWebContext, CustomExecutionSupportedContext, ShellExecutionSupportedContext, ProcessExecutionSupportedContext, TaskExecutionSupportedContext } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/tasks/common/taskService';
|
|
48
48
|
import { VerifiedTask, Triggers, TaskError, TaskErrors, TaskExecuteKind } from '../common/taskSystem.js';
|
|
49
49
|
import { getTemplates } from '../common/taskTemplates.js';
|
|
50
|
-
import { createCustomTask, TaskConfigSource, GroupKind, parse, ExecutionEngine as ExecutionEngine$1, JsonSchemaVersion as JsonSchemaVersion$1 } from '
|
|
50
|
+
import { createCustomTask, TaskConfigSource, GroupKind, parse, ExecutionEngine as ExecutionEngine$1, JsonSchemaVersion as JsonSchemaVersion$1 } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/tasks/common/taskConfiguration';
|
|
51
51
|
import { TerminalTaskSystem } from './terminalTaskSystem.js';
|
|
52
52
|
import { IQuickInputService } from '@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput.service';
|
|
53
53
|
import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service';
|
|
@@ -93,7 +93,7 @@ const TaskTerminalType = "Task";
|
|
|
93
93
|
var ConfigureTaskAction;
|
|
94
94
|
(function(ConfigureTaskAction) {
|
|
95
95
|
ConfigureTaskAction.ID = "workbench.action.tasks.configureTaskRunner";
|
|
96
|
-
ConfigureTaskAction.TEXT = ( localize2(
|
|
96
|
+
ConfigureTaskAction.TEXT = ( localize2(12576, "Configure Task"));
|
|
97
97
|
})(ConfigureTaskAction || (ConfigureTaskAction = {}));
|
|
98
98
|
class ProblemReporter {
|
|
99
99
|
constructor(_outputChannel) {
|
|
@@ -185,7 +185,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
185
185
|
this.OutputChannelId = "tasks";
|
|
186
186
|
}
|
|
187
187
|
static {
|
|
188
|
-
this.OutputChannelLabel = ( localize(
|
|
188
|
+
this.OutputChannelLabel = ( localize(12577, "Tasks"));
|
|
189
189
|
}
|
|
190
190
|
static {
|
|
191
191
|
this._nextHandle = 0;
|
|
@@ -359,7 +359,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
359
359
|
}
|
|
360
360
|
let entry;
|
|
361
361
|
if (tasks && tasks.length > 0) {
|
|
362
|
-
entry = await this._showQuickPick(tasks, ( localize(
|
|
362
|
+
entry = await this._showQuickPick(tasks, ( localize(12578, "Select the build task (there is no default build task defined)")));
|
|
363
363
|
}
|
|
364
364
|
const task = entry ? entry.task : undefined;
|
|
365
365
|
if (!task) {
|
|
@@ -371,7 +371,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
371
371
|
this._willRestart = e.reason !== ShutdownReason.RELOAD;
|
|
372
372
|
}));
|
|
373
373
|
this._register(this.onDidStateChange(async e => {
|
|
374
|
-
this._log(( localize(
|
|
374
|
+
this._log(( localize(12579, "Task Event kind: {0}", e.kind)), true);
|
|
375
375
|
switch (e.kind) {
|
|
376
376
|
case TaskEventKind.Start:
|
|
377
377
|
this._taskRunStartTimes.set(e.taskId, Date.now());
|
|
@@ -458,7 +458,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
458
458
|
_attemptTaskReconnection() {
|
|
459
459
|
if (!this._lifecycleService.shouldAttemptTaskReconnection) {
|
|
460
460
|
this._log(( localize(
|
|
461
|
-
|
|
461
|
+
12580,
|
|
462
462
|
"Startup kind not window reload, setting connected and removing persistent tasks"
|
|
463
463
|
)), true);
|
|
464
464
|
this._tasksReconnected = true;
|
|
@@ -466,7 +466,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
466
466
|
}
|
|
467
467
|
if (!this._configurationService.getValue(TaskSettingId.Reconnection) || this._tasksReconnected) {
|
|
468
468
|
this._log(( localize(
|
|
469
|
-
|
|
469
|
+
12581,
|
|
470
470
|
"Setting tasks connected configured value {0}, tasks were already reconnected {1}",
|
|
471
471
|
this._configurationService.getValue(TaskSettingId.Reconnection),
|
|
472
472
|
this._tasksReconnected
|
|
@@ -474,10 +474,10 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
474
474
|
this._tasksReconnected = true;
|
|
475
475
|
return;
|
|
476
476
|
}
|
|
477
|
-
this._log(( localize(
|
|
477
|
+
this._log(( localize(12582, "Reconnecting to running tasks...")), true);
|
|
478
478
|
this.getWorkspaceTasks(TaskRunSource.Reconnect).then(async () => {
|
|
479
479
|
this._tasksReconnected = await this._reconnectTasks();
|
|
480
|
-
this._log(( localize(
|
|
480
|
+
this._log(( localize(12583, "Reconnected to running tasks.")), true);
|
|
481
481
|
this._onDidReconnectToTasks.fire();
|
|
482
482
|
});
|
|
483
483
|
}
|
|
@@ -500,7 +500,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
500
500
|
return;
|
|
501
501
|
}
|
|
502
502
|
const durationText = this._formatTaskDuration(durationMs);
|
|
503
|
-
const message = taskLabel ? ( localize(
|
|
503
|
+
const message = taskLabel ? ( localize(12584, "Task \"{0}\" finished in {1}.", taskLabel, durationText)) : ( localize(12585, "Task finished in {0}.", durationText));
|
|
504
504
|
this._hostService.focus(targetWindow, {
|
|
505
505
|
mode: FocusMode.Notify
|
|
506
506
|
});
|
|
@@ -523,18 +523,18 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
523
523
|
const minutes = Math.floor(totalSeconds / 60);
|
|
524
524
|
const seconds = totalSeconds % 60;
|
|
525
525
|
if (minutes > 0) {
|
|
526
|
-
return seconds > 0 ? ( localize(
|
|
526
|
+
return seconds > 0 ? ( localize(12586, "{0}m {1}s", minutes, seconds)) : ( localize(12587, "{0}m", minutes));
|
|
527
527
|
}
|
|
528
|
-
return localize(
|
|
528
|
+
return localize(12588, "{0}s", seconds);
|
|
529
529
|
}
|
|
530
530
|
async _reconnectTasks() {
|
|
531
531
|
const tasks = await this.getSavedTasks("persistent");
|
|
532
532
|
if (!tasks.length) {
|
|
533
|
-
this._log(( localize(
|
|
533
|
+
this._log(( localize(12589, "No persistent tasks to reconnect.")), true);
|
|
534
534
|
return true;
|
|
535
535
|
}
|
|
536
536
|
const taskLabels = ( tasks.map(task => task._label)).join(", ");
|
|
537
|
-
this._log(( localize(
|
|
537
|
+
this._log(( localize(12590, "Reconnecting to {0} tasks...", taskLabels)), true);
|
|
538
538
|
for (const task of tasks) {
|
|
539
539
|
if (ConfiguringTask.is(task)) {
|
|
540
540
|
const resolved = await this.tryResolveTask(task);
|
|
@@ -566,21 +566,21 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
566
566
|
args: [{
|
|
567
567
|
name: "args",
|
|
568
568
|
isOptional: true,
|
|
569
|
-
description: ( localize(
|
|
569
|
+
description: ( localize(12591, "Filters the tasks shown in the quickpick")),
|
|
570
570
|
schema: {
|
|
571
571
|
anyOf: [{
|
|
572
572
|
type: "string",
|
|
573
|
-
description: ( localize(
|
|
573
|
+
description: ( localize(12592, "The task's label or a term to filter by"))
|
|
574
574
|
}, {
|
|
575
575
|
type: "object",
|
|
576
576
|
properties: {
|
|
577
577
|
type: {
|
|
578
578
|
type: "string",
|
|
579
|
-
description: ( localize(
|
|
579
|
+
description: ( localize(12593, "The contributed task type"))
|
|
580
580
|
},
|
|
581
581
|
task: {
|
|
582
582
|
type: "string",
|
|
583
|
-
description: ( localize(
|
|
583
|
+
description: ( localize(12594, "The task's label or a term to filter by"))
|
|
584
584
|
}
|
|
585
585
|
}
|
|
586
586
|
}]
|
|
@@ -755,7 +755,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
755
755
|
const defaultAgent = this._chatAgentService.getDefaultAgent(ChatAgentLocation.Chat);
|
|
756
756
|
if (defaultAgent) {
|
|
757
757
|
actions.push({
|
|
758
|
-
label: ( localize(
|
|
758
|
+
label: ( localize(12595, "Fix with AI")),
|
|
759
759
|
run: async () => {
|
|
760
760
|
this._commandService.executeCommand(CHAT_OPEN_ACTION_ID, {
|
|
761
761
|
mode: ChatModeKind.Agent,
|
|
@@ -767,18 +767,18 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
767
767
|
}
|
|
768
768
|
}
|
|
769
769
|
actions.push({
|
|
770
|
-
label: ( localize(
|
|
770
|
+
label: ( localize(12596, "Show Output")),
|
|
771
771
|
run: () => {
|
|
772
772
|
this._outputService.showChannel(this._outputChannel.id, true);
|
|
773
773
|
}
|
|
774
774
|
});
|
|
775
775
|
if (chatEnabled && actions.length > 1) {
|
|
776
776
|
this._notificationService.prompt(Severity.Warning, ( localize(
|
|
777
|
-
|
|
777
|
+
12597,
|
|
778
778
|
"There are task errors. Use chat to fix them or view the output for details."
|
|
779
779
|
)), actions);
|
|
780
780
|
} else {
|
|
781
|
-
this._notificationService.prompt(Severity.Warning, ( localize(
|
|
781
|
+
this._notificationService.prompt(Severity.Warning, ( localize(12598, "There are task errors. See the output for details.")), actions);
|
|
782
782
|
}
|
|
783
783
|
}
|
|
784
784
|
}
|
|
@@ -879,7 +879,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
879
879
|
}
|
|
880
880
|
const name = isString(folder) ? folder : isWorkspaceFolder(folder) ? folder.name : folder.configuration ? basename(folder.configuration) : undefined;
|
|
881
881
|
if (( this.ignoredWorkspaceFolders.some(ignored => ignored.name === name))) {
|
|
882
|
-
return Promise.reject(( new Error(( localize(
|
|
882
|
+
return Promise.reject(( new Error(( localize(12599, "The folder {0} is ignored since it uses task version 0.1.0", name)))));
|
|
883
883
|
}
|
|
884
884
|
const key = !isString(identifier) ? TaskDefinition.createTaskIdentifier(identifier, console) : identifier;
|
|
885
885
|
if (key === undefined) {
|
|
@@ -934,7 +934,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
934
934
|
if (!matchingProvider) {
|
|
935
935
|
if (matchingProviderUnavailable) {
|
|
936
936
|
this._log(( localize(
|
|
937
|
-
|
|
937
|
+
12600,
|
|
938
938
|
"Warning: {0} tasks are unavailable in the current environment.",
|
|
939
939
|
configuringTask.configures.type
|
|
940
940
|
)));
|
|
@@ -1072,7 +1072,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1072
1072
|
}
|
|
1073
1073
|
_getPersistentTasks() {
|
|
1074
1074
|
if (this._persistentTasks) {
|
|
1075
|
-
this._log(( localize(
|
|
1075
|
+
this._log(( localize(12601, "Returning cached tasks {0}", this._persistentTasks.size)), true);
|
|
1076
1076
|
return this._persistentTasks;
|
|
1077
1077
|
}
|
|
1078
1078
|
this._persistentTasks = ( new LRUCache(10));
|
|
@@ -1105,7 +1105,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1105
1105
|
const workspaceToTaskMap = ( new Map());
|
|
1106
1106
|
const storedTasks = this._getTasksFromStorage(type);
|
|
1107
1107
|
const tasks = [];
|
|
1108
|
-
this._log(( localize(
|
|
1108
|
+
this._log(( localize(12602, "Fetching tasks from task storage.")), true);
|
|
1109
1109
|
function addTaskToMap(map, folder, task) {
|
|
1110
1110
|
if (folder && !( map.has(folder))) {
|
|
1111
1111
|
map.set(folder, []);
|
|
@@ -1120,7 +1120,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1120
1120
|
const task = JSON.parse(entry[1]);
|
|
1121
1121
|
const folderInfo = this._getFolderFromTaskKey(key);
|
|
1122
1122
|
this._log(( localize(
|
|
1123
|
-
|
|
1123
|
+
12603,
|
|
1124
1124
|
"Reading tasks from task storage, {0}, {1}, {2}",
|
|
1125
1125
|
key,
|
|
1126
1126
|
task,
|
|
@@ -1132,7 +1132,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1132
1132
|
task
|
|
1133
1133
|
);
|
|
1134
1134
|
} catch (error) {
|
|
1135
|
-
this._log(( localize(
|
|
1135
|
+
this._log(( localize(12604, "Fetching a task from task storage failed: {0}.", error)), true);
|
|
1136
1136
|
}
|
|
1137
1137
|
}
|
|
1138
1138
|
const readTasksMap = ( new Map());
|
|
@@ -1164,9 +1164,9 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1164
1164
|
for (const key of ( storedTasks.keys())) {
|
|
1165
1165
|
if (( readTasksMap.has(key))) {
|
|
1166
1166
|
tasks.push(readTasksMap.get(key));
|
|
1167
|
-
this._log(( localize(
|
|
1167
|
+
this._log(( localize(12605, "Resolved task {0}", key)), true);
|
|
1168
1168
|
} else {
|
|
1169
|
-
this._log(( localize(
|
|
1169
|
+
this._log(( localize(12606, "Unable to resolve task {0} ", key)), true);
|
|
1170
1170
|
}
|
|
1171
1171
|
}
|
|
1172
1172
|
return tasks;
|
|
@@ -1177,7 +1177,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1177
1177
|
}
|
|
1178
1178
|
}
|
|
1179
1179
|
removePersistentTask(key) {
|
|
1180
|
-
this._log(( localize(
|
|
1180
|
+
this._log(( localize(12607, "Removing persistent task {0}", key)), true);
|
|
1181
1181
|
if (this._getTasksFromStorage("persistent").delete(key)) {
|
|
1182
1182
|
this._savePersistentTasks();
|
|
1183
1183
|
}
|
|
@@ -1251,7 +1251,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1251
1251
|
if (!task.configurationProperties.isBackground) {
|
|
1252
1252
|
return;
|
|
1253
1253
|
}
|
|
1254
|
-
this._log(( localize(
|
|
1254
|
+
this._log(( localize(12608, "Setting persistent task {0}", key)), true);
|
|
1255
1255
|
this._getTasksFromStorage("persistent").set(key, JSON.stringify(customizations));
|
|
1256
1256
|
this._savePersistentTasks();
|
|
1257
1257
|
}
|
|
@@ -1263,7 +1263,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1263
1263
|
for (const key of keys) {
|
|
1264
1264
|
keyValues.push([key, this._persistentTasks.get(key, Touch.None)]);
|
|
1265
1265
|
}
|
|
1266
|
-
this._log(( localize(
|
|
1266
|
+
this._log(( localize(12609, "Saving persistent tasks: {0}", keys.join(", "))), true);
|
|
1267
1267
|
this._storageService.store(
|
|
1268
1268
|
AbstractTaskService_1.PersistentTasks_Key,
|
|
1269
1269
|
JSON.stringify(keyValues),
|
|
@@ -1312,24 +1312,24 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1312
1312
|
if (test) {
|
|
1313
1313
|
if (this.schemaVersion === JsonSchemaVersion.V0_1_0) {
|
|
1314
1314
|
throw ( new TaskError(Severity.Info, ( localize(
|
|
1315
|
-
|
|
1315
|
+
12610,
|
|
1316
1316
|
"No test task defined. Mark a task with 'isTestCommand' in the tasks.json file."
|
|
1317
1317
|
)), TaskErrors.NoTestTask));
|
|
1318
1318
|
} else {
|
|
1319
1319
|
throw ( new TaskError(Severity.Info, ( localize(
|
|
1320
|
-
|
|
1320
|
+
12611,
|
|
1321
1321
|
"No test task defined. Mark a task with as a 'test' group in the tasks.json file."
|
|
1322
1322
|
)), TaskErrors.NoTestTask));
|
|
1323
1323
|
}
|
|
1324
1324
|
} else {
|
|
1325
1325
|
if (this.schemaVersion === JsonSchemaVersion.V0_1_0) {
|
|
1326
1326
|
throw ( new TaskError(Severity.Info, ( localize(
|
|
1327
|
-
|
|
1327
|
+
12612,
|
|
1328
1328
|
"No build task defined. Mark a task with 'isBuildCommand' in the tasks.json file."
|
|
1329
1329
|
)), TaskErrors.NoBuildTask));
|
|
1330
1330
|
} else {
|
|
1331
1331
|
throw ( new TaskError(Severity.Info, ( localize(
|
|
1332
|
-
|
|
1332
|
+
12613,
|
|
1333
1333
|
"No build task defined. Mark a task with as a 'build' group in the tasks.json file."
|
|
1334
1334
|
)), TaskErrors.NoBuildTask));
|
|
1335
1335
|
}
|
|
@@ -1349,7 +1349,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1349
1349
|
return;
|
|
1350
1350
|
}
|
|
1351
1351
|
if (!task) {
|
|
1352
|
-
throw ( new TaskError(Severity.Info, ( localize(
|
|
1352
|
+
throw ( new TaskError(Severity.Info, ( localize(12614, "Task to execute is undefined")), TaskErrors.TaskNotFound));
|
|
1353
1353
|
}
|
|
1354
1354
|
const resolver = this._createResolver();
|
|
1355
1355
|
let executeTaskResult;
|
|
@@ -1462,7 +1462,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1462
1462
|
});
|
|
1463
1463
|
entries.unshift({
|
|
1464
1464
|
type: "separator",
|
|
1465
|
-
label: ( localize(
|
|
1465
|
+
label: ( localize(12615, "associate"))
|
|
1466
1466
|
});
|
|
1467
1467
|
let taskType;
|
|
1468
1468
|
if (CustomTask.is(task)) {
|
|
@@ -1472,24 +1472,24 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1472
1472
|
taskType = task.getDefinition().type;
|
|
1473
1473
|
}
|
|
1474
1474
|
entries.unshift({
|
|
1475
|
-
label: ( localize(
|
|
1475
|
+
label: ( localize(12616, "Continue without scanning the task output")),
|
|
1476
1476
|
matcher: undefined
|
|
1477
1477
|
}, {
|
|
1478
|
-
label: ( localize(
|
|
1478
|
+
label: ( localize(12617, "Never scan the task output for this task")),
|
|
1479
1479
|
matcher: undefined,
|
|
1480
1480
|
never: true
|
|
1481
1481
|
}, {
|
|
1482
|
-
label: ( localize(
|
|
1482
|
+
label: ( localize(12618, "Never scan the task output for {0} tasks", taskType)),
|
|
1483
1483
|
matcher: undefined,
|
|
1484
1484
|
setting: taskType
|
|
1485
1485
|
}, {
|
|
1486
|
-
label: ( localize(
|
|
1486
|
+
label: ( localize(12619, "Learn more about scanning the task output")),
|
|
1487
1487
|
matcher: undefined,
|
|
1488
1488
|
learnMore: true
|
|
1489
1489
|
});
|
|
1490
1490
|
const problemMatcher = await this._quickInputService.pick(entries, {
|
|
1491
1491
|
placeHolder: ( localize(
|
|
1492
|
-
|
|
1492
|
+
12620,
|
|
1493
1493
|
"Select for which kind of errors and warnings to scan the task output"
|
|
1494
1494
|
))
|
|
1495
1495
|
});
|
|
@@ -1679,7 +1679,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1679
1679
|
const configuration = this._getConfiguration(workspaceFolder, task._source.kind);
|
|
1680
1680
|
if (configuration.hasParseErrors) {
|
|
1681
1681
|
this._notificationService.warn(( localize(
|
|
1682
|
-
|
|
1682
|
+
12621,
|
|
1683
1683
|
"The current task configuration has errors. Please fix the errors first before customizing a task."
|
|
1684
1684
|
)));
|
|
1685
1685
|
return Promise.resolve(undefined);
|
|
@@ -1704,7 +1704,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1704
1704
|
tasks: [toCustomize]
|
|
1705
1705
|
};
|
|
1706
1706
|
let content = ["{", ( localize(
|
|
1707
|
-
|
|
1707
|
+
12622,
|
|
1708
1708
|
"\t// See https://go.microsoft.com/fwlink/?LinkId=733558 \n\t// for the documentation about the tasks.json format"
|
|
1709
1709
|
))].join("\n") + JSON.stringify(value, null, "\t").substr(1);
|
|
1710
1710
|
const editorConfig = this._configurationService.getValue();
|
|
@@ -1864,7 +1864,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1864
1864
|
if (workspaceTasks.length > 0) {
|
|
1865
1865
|
if (workspaceTasks.length > 1) {
|
|
1866
1866
|
this._log(( localize(
|
|
1867
|
-
|
|
1867
|
+
12623,
|
|
1868
1868
|
"There are many build tasks defined in the tasks.json. Executing the first one."
|
|
1869
1869
|
)));
|
|
1870
1870
|
}
|
|
@@ -1997,10 +1997,10 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
1997
1997
|
const {
|
|
1998
1998
|
confirmed
|
|
1999
1999
|
} = await this._dialogService.confirm({
|
|
2000
|
-
message: ( localize(
|
|
2001
|
-
detail: ( localize(
|
|
2002
|
-
primaryButton: ( localize(
|
|
2003
|
-
cancelButton: ( localize(
|
|
2000
|
+
message: ( localize(12624, "Save all editors?")),
|
|
2001
|
+
detail: ( localize(12625, "Do you want to save all editors before running the task?")),
|
|
2002
|
+
primaryButton: ( localize(12626, "&&Save")),
|
|
2003
|
+
cancelButton: ( localize(12627, "Do&&n't Save"))
|
|
2004
2004
|
});
|
|
2005
2005
|
if (!confirmed) {
|
|
2006
2006
|
return false;
|
|
@@ -2047,7 +2047,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2047
2047
|
this._handleInstancePolicy(executeResult.task, executeResult.task.runOptions.instancePolicy);
|
|
2048
2048
|
} else {
|
|
2049
2049
|
throw ( new TaskError(Severity.Warning, ( localize(
|
|
2050
|
-
|
|
2050
|
+
12628,
|
|
2051
2051
|
"There is already a task running. Terminate it first before executing another task."
|
|
2052
2052
|
)), TaskErrors.RunningTask));
|
|
2053
2053
|
}
|
|
@@ -2069,15 +2069,15 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2069
2069
|
case InstancePolicy.silent:
|
|
2070
2070
|
break;
|
|
2071
2071
|
case InstancePolicy.warn:
|
|
2072
|
-
this._notificationService.warn(( localize(
|
|
2072
|
+
this._notificationService.warn(( localize(12629, "The instance limit for this task has been reached.")));
|
|
2073
2073
|
break;
|
|
2074
2074
|
case InstancePolicy.prompt:
|
|
2075
2075
|
default:
|
|
2076
2076
|
this._showQuickPick(
|
|
2077
2077
|
this._taskSystem.getActiveTasks().filter(t => task._id === t._id),
|
|
2078
|
-
( localize(
|
|
2078
|
+
( localize(12630, "Select an instance to terminate")),
|
|
2079
2079
|
{
|
|
2080
|
-
label: ( localize(
|
|
2080
|
+
label: ( localize(12631, "No instance is currently running")),
|
|
2081
2081
|
task: undefined
|
|
2082
2082
|
},
|
|
2083
2083
|
false,
|
|
@@ -2101,7 +2101,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2101
2101
|
const response = await this._taskSystem.terminate(task);
|
|
2102
2102
|
if (!response.success) {
|
|
2103
2103
|
this._notificationService.warn(( localize(
|
|
2104
|
-
|
|
2104
|
+
12632,
|
|
2105
2105
|
"Failed to terminate and restart task {0}",
|
|
2106
2106
|
isString(task) ? task : task.configurationProperties.name
|
|
2107
2107
|
)));
|
|
@@ -2116,7 +2116,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2116
2116
|
const success = await this.run(task);
|
|
2117
2117
|
if (!success || (typeof success.exitCode === "number" && success.exitCode !== 0)) {
|
|
2118
2118
|
this._notificationService.warn(( localize(
|
|
2119
|
-
|
|
2119
|
+
12633,
|
|
2120
2120
|
"Task {0} no longer exists or has been modified. Cannot restart.",
|
|
2121
2121
|
task.configurationProperties.name
|
|
2122
2122
|
)));
|
|
@@ -2282,7 +2282,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2282
2282
|
for (const task of taskSet.tasks) {
|
|
2283
2283
|
if (task.type !== this._providerTypes.get(handle)) {
|
|
2284
2284
|
this._log(( localize(
|
|
2285
|
-
|
|
2285
|
+
12634,
|
|
2286
2286
|
"The task provider for \"{0}\" tasks unexpectedly provided a task of type \"{1}\".\n",
|
|
2287
2287
|
this._providerTypes.get(handle),
|
|
2288
2288
|
task.type
|
|
@@ -2424,13 +2424,13 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2424
2424
|
}
|
|
2425
2425
|
if (requiredTaskProviderUnavailable) {
|
|
2426
2426
|
this._log(( localize(
|
|
2427
|
-
|
|
2427
|
+
12600,
|
|
2428
2428
|
"Warning: {0} tasks are unavailable in the current environment.",
|
|
2429
2429
|
configuringTask.configures.type
|
|
2430
2430
|
)));
|
|
2431
2431
|
} else if (!waitToActivate) {
|
|
2432
2432
|
this._log(( localize(
|
|
2433
|
-
|
|
2433
|
+
12635,
|
|
2434
2434
|
"Error: The {0} task detection didn't contribute a task for the following configuration:\n{1}\nThe task will be ignored.",
|
|
2435
2435
|
configuringTask.configures.type,
|
|
2436
2436
|
JSON.stringify(configuringTask._source.config.element, undefined, 4)
|
|
@@ -2566,7 +2566,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2566
2566
|
}
|
|
2567
2567
|
if (problemReporter.status.isFatal()) {
|
|
2568
2568
|
problemReporter.fatal(( localize(
|
|
2569
|
-
|
|
2569
|
+
12636,
|
|
2570
2570
|
"Error: the provided task configuration has validation errors and can't not be used. Please correct the errors first."
|
|
2571
2571
|
)));
|
|
2572
2572
|
return {
|
|
@@ -2615,12 +2615,12 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2615
2615
|
}
|
|
2616
2616
|
if (isAffected) {
|
|
2617
2617
|
this._log(( localize(
|
|
2618
|
-
|
|
2618
|
+
12637,
|
|
2619
2619
|
"Error: The content of the tasks json in {0} has syntax errors. Please correct them before executing a task.",
|
|
2620
2620
|
location
|
|
2621
2621
|
)));
|
|
2622
2622
|
this._showOutput(undefined, undefined, ( localize(
|
|
2623
|
-
|
|
2623
|
+
12637,
|
|
2624
2624
|
"Error: The content of the tasks json in {0} has syntax errors. Please correct them before executing a task.",
|
|
2625
2625
|
location
|
|
2626
2626
|
)));
|
|
@@ -2645,7 +2645,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2645
2645
|
return this._emptyWorkspaceTaskResults(workspaceFolder);
|
|
2646
2646
|
}
|
|
2647
2647
|
const workspaceFileConfig = this._getConfiguration(workspaceFolder, TaskSourceKind.WorkspaceFile);
|
|
2648
|
-
const configuration = this._testParseExternalConfig(workspaceFileConfig.config, ( localize(
|
|
2648
|
+
const configuration = this._testParseExternalConfig(workspaceFileConfig.config, ( localize(12638, "workspace file")));
|
|
2649
2649
|
const customizedTasks = {
|
|
2650
2650
|
byIdentifier: Object.create(null)
|
|
2651
2651
|
};
|
|
@@ -2661,7 +2661,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2661
2661
|
const engine = configuration.config ? ExecutionEngine$1.from(configuration.config) : ExecutionEngine.Terminal;
|
|
2662
2662
|
if (engine === ExecutionEngine.Process) {
|
|
2663
2663
|
this._notificationService.warn(( localize(
|
|
2664
|
-
|
|
2664
|
+
12639,
|
|
2665
2665
|
"Only tasks version 2.0.0 permitted in workspace configuration files."
|
|
2666
2666
|
)));
|
|
2667
2667
|
return this._emptyWorkspaceTaskResults(workspaceFolder);
|
|
@@ -2680,7 +2680,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2680
2680
|
return this._emptyWorkspaceTaskResults(workspaceFolder);
|
|
2681
2681
|
}
|
|
2682
2682
|
const userTasksConfig = this._getConfiguration(workspaceFolder, TaskSourceKind.User);
|
|
2683
|
-
const configuration = this._testParseExternalConfig(userTasksConfig.config, ( localize(
|
|
2683
|
+
const configuration = this._testParseExternalConfig(userTasksConfig.config, ( localize(12640, "user settings")));
|
|
2684
2684
|
const customizedTasks = {
|
|
2685
2685
|
byIdentifier: Object.create(null)
|
|
2686
2686
|
};
|
|
@@ -2695,7 +2695,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2695
2695
|
);
|
|
2696
2696
|
const engine = configuration.config ? ExecutionEngine$1.from(configuration.config) : ExecutionEngine.Terminal;
|
|
2697
2697
|
if (engine === ExecutionEngine.Process) {
|
|
2698
|
-
this._notificationService.warn(( localize(
|
|
2698
|
+
this._notificationService.warn(( localize(12641, "Only tasks version 2.0.0 permitted in user settings.")));
|
|
2699
2699
|
return this._emptyWorkspaceTaskResults(workspaceFolder);
|
|
2700
2700
|
}
|
|
2701
2701
|
return {
|
|
@@ -2752,7 +2752,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2752
2752
|
}
|
|
2753
2753
|
if (problemReporter.status.isFatal()) {
|
|
2754
2754
|
problemReporter.fatal(( localize(
|
|
2755
|
-
|
|
2755
|
+
12636,
|
|
2756
2756
|
"Error: the provided task configuration has validation errors and can't not be used. Please correct the errors first."
|
|
2757
2757
|
)));
|
|
2758
2758
|
return hasErrors;
|
|
@@ -2801,7 +2801,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2801
2801
|
} else {
|
|
2802
2802
|
ignoredWorkspaceFolders.push(workspaceFolder);
|
|
2803
2803
|
this._log(( localize(
|
|
2804
|
-
|
|
2804
|
+
12642,
|
|
2805
2805
|
"Ignoring task configurations for workspace folder {0}. Multi folder workspace task support requires that all folders use task version 2.0.0",
|
|
2806
2806
|
workspaceFolder.uri.fsPath
|
|
2807
2807
|
)));
|
|
@@ -2881,11 +2881,11 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2881
2881
|
}
|
|
2882
2882
|
if (isAffected) {
|
|
2883
2883
|
this._log(( localize(
|
|
2884
|
-
|
|
2884
|
+
12643,
|
|
2885
2885
|
"Error: The content of the tasks.json file has syntax errors. Please correct them before executing a task."
|
|
2886
2886
|
)));
|
|
2887
2887
|
this._showOutput(undefined, undefined, ( localize(
|
|
2888
|
-
|
|
2888
|
+
12643,
|
|
2889
2889
|
"Error: The content of the tasks.json file has syntax errors. Please correct them before executing a task."
|
|
2890
2890
|
)));
|
|
2891
2891
|
return {
|
|
@@ -2930,7 +2930,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2930
2930
|
const needsTerminate = buildError.code === TaskErrors.RunningTask;
|
|
2931
2931
|
if (needsConfig || needsTerminate) {
|
|
2932
2932
|
this._notificationService.prompt(buildError.severity, buildError.message, [{
|
|
2933
|
-
label: needsConfig ? ConfigureTaskAction.TEXT.value : ( localize(
|
|
2933
|
+
label: needsConfig ? ConfigureTaskAction.TEXT.value : ( localize(12644, "Terminate Task")),
|
|
2934
2934
|
run: () => {
|
|
2935
2935
|
if (needsConfig) {
|
|
2936
2936
|
this._runConfigureTasks();
|
|
@@ -2953,7 +2953,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2953
2953
|
this._notificationService.error(err);
|
|
2954
2954
|
} else {
|
|
2955
2955
|
this._notificationService.error(( localize(
|
|
2956
|
-
|
|
2956
|
+
12645,
|
|
2957
2957
|
"An error has occurred while running a task. See task log for details."
|
|
2958
2958
|
)));
|
|
2959
2959
|
}
|
|
@@ -2998,7 +2998,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
2998
2998
|
const entry = TaskQuickPickEntry(task);
|
|
2999
2999
|
entry.buttons = [{
|
|
3000
3000
|
iconClass: ThemeIcon.asClassName(configureTaskIcon),
|
|
3001
|
-
tooltip: ( localize(
|
|
3001
|
+
tooltip: ( localize(12646, "Configure Task"))
|
|
3002
3002
|
}];
|
|
3003
3003
|
if (selectedEntry && (task === selectedEntry.task)) {
|
|
3004
3004
|
entries.unshift(selectedEntry);
|
|
@@ -3047,12 +3047,12 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3047
3047
|
}
|
|
3048
3048
|
const sorter = this.createSorter();
|
|
3049
3049
|
if (includeRecents) {
|
|
3050
|
-
fillEntries(entries, recent, ( localize(
|
|
3050
|
+
fillEntries(entries, recent, ( localize(12647, "recently used tasks")));
|
|
3051
3051
|
}
|
|
3052
3052
|
configured = configured.sort((a, b) => sorter.compare(a, b));
|
|
3053
|
-
fillEntries(entries, configured, ( localize(
|
|
3053
|
+
fillEntries(entries, configured, ( localize(12648, "configured tasks")));
|
|
3054
3054
|
detected = detected.sort((a, b) => sorter.compare(a, b));
|
|
3055
|
-
fillEntries(entries, detected, ( localize(
|
|
3055
|
+
fillEntries(entries, detected, ( localize(12649, "detected tasks")));
|
|
3056
3056
|
}
|
|
3057
3057
|
} else {
|
|
3058
3058
|
if (sort) {
|
|
@@ -3146,11 +3146,11 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3146
3146
|
return Promise.resolve(undefined);
|
|
3147
3147
|
}
|
|
3148
3148
|
this._notificationService.prompt(Severity.Info, ( localize(
|
|
3149
|
-
|
|
3149
|
+
12650,
|
|
3150
3150
|
"The following workspace folders are ignored since they use task version 0.1.0: {0}",
|
|
3151
3151
|
( this.ignoredWorkspaceFolders.map(f => f.name)).join(", ")
|
|
3152
3152
|
)), [{
|
|
3153
|
-
label: ( localize(
|
|
3153
|
+
label: ( localize(12651, "Don't Show Again")),
|
|
3154
3154
|
isSecondary: true,
|
|
3155
3155
|
run: () => {
|
|
3156
3156
|
this._storageService.store(
|
|
@@ -3173,7 +3173,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3173
3173
|
if (!this._workspaceTrustManagementService.isWorkspaceTrusted()) {
|
|
3174
3174
|
return (await this._workspaceTrustRequestService.requestWorkspaceTrust({
|
|
3175
3175
|
message: ( localize(
|
|
3176
|
-
|
|
3176
|
+
12652,
|
|
3177
3177
|
"Listing and running tasks requires that some of the files in this workspace be executed as code."
|
|
3178
3178
|
))
|
|
3179
3179
|
})) === true;
|
|
@@ -3272,7 +3272,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3272
3272
|
}, TaskRunSource.User).then(undefined, reason => {});
|
|
3273
3273
|
}
|
|
3274
3274
|
};
|
|
3275
|
-
const placeholder = ( localize(
|
|
3275
|
+
const placeholder = ( localize(12653, "Select the task to run"));
|
|
3276
3276
|
this._showIgnoredFoldersMessage().then(() => {
|
|
3277
3277
|
if (this._configurationService.getValue(USE_SLOW_PICKER)) {
|
|
3278
3278
|
let taskResult = undefined;
|
|
@@ -3280,14 +3280,14 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3280
3280
|
taskResult = this._tasksAndGroupedTasks();
|
|
3281
3281
|
}
|
|
3282
3282
|
this._showQuickPick(tasks ? tasks : taskResult.tasks, placeholder, {
|
|
3283
|
-
label: "$(plus) " + ( localize(
|
|
3283
|
+
label: "$(plus) " + ( localize(12654, "Configure a Task")),
|
|
3284
3284
|
task: null
|
|
3285
3285
|
}, true, undefined, undefined, undefined, name).then(entry => {
|
|
3286
3286
|
return pickThen(entry ? entry.task : undefined);
|
|
3287
3287
|
});
|
|
3288
3288
|
} else {
|
|
3289
3289
|
this._showTwoLevelQuickPick(placeholder, {
|
|
3290
|
-
label: "$(plus) " + ( localize(
|
|
3290
|
+
label: "$(plus) " + ( localize(12654, "Configure a Task")),
|
|
3291
3291
|
task: null
|
|
3292
3292
|
}, type, name).then(pickThen);
|
|
3293
3293
|
}
|
|
@@ -3451,16 +3451,16 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3451
3451
|
return;
|
|
3452
3452
|
}
|
|
3453
3453
|
return this._runTaskGroupCommand(TaskGroup.Build, {
|
|
3454
|
-
fetching: ( localize(
|
|
3455
|
-
select: ( localize(
|
|
3456
|
-
notFoundConfigure: ( localize(
|
|
3454
|
+
fetching: ( localize(12655, "Fetching build tasks...")),
|
|
3455
|
+
select: ( localize(12656, "Select the build task to run")),
|
|
3456
|
+
notFoundConfigure: ( localize(12657, "No build task to run found. Configure Build Task..."))
|
|
3457
3457
|
}, this._runConfigureDefaultBuildTask, this._build);
|
|
3458
3458
|
}
|
|
3459
3459
|
_runTestCommand() {
|
|
3460
3460
|
return this._runTaskGroupCommand(TaskGroup.Test, {
|
|
3461
|
-
fetching: ( localize(
|
|
3462
|
-
select: ( localize(
|
|
3463
|
-
notFoundConfigure: ( localize(
|
|
3461
|
+
fetching: ( localize(12658, "Fetching test tasks...")),
|
|
3462
|
+
select: ( localize(12659, "Select the test task to run")),
|
|
3463
|
+
notFoundConfigure: ( localize(12660, "No test task to run found. Configure Tasks..."))
|
|
3464
3464
|
}, this._runConfigureDefaultTestTask, this._runTest);
|
|
3465
3465
|
}
|
|
3466
3466
|
_runTerminateCommand(arg) {
|
|
@@ -3469,11 +3469,11 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3469
3469
|
return;
|
|
3470
3470
|
}
|
|
3471
3471
|
const runQuickPick = promise => {
|
|
3472
|
-
this._showQuickPick(promise || this.getActiveTasks(), ( localize(
|
|
3473
|
-
label: ( localize(
|
|
3472
|
+
this._showQuickPick(promise || this.getActiveTasks(), ( localize(12661, "Select a task to terminate")), {
|
|
3473
|
+
label: ( localize(12662, "No task is currently running")),
|
|
3474
3474
|
task: undefined
|
|
3475
3475
|
}, false, true, undefined, [{
|
|
3476
|
-
label: ( localize(
|
|
3476
|
+
label: ( localize(12663, "All Running Tasks")),
|
|
3477
3477
|
id: "terminateAll",
|
|
3478
3478
|
task: undefined
|
|
3479
3479
|
}]).then(entry => {
|
|
@@ -3514,11 +3514,11 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3514
3514
|
}
|
|
3515
3515
|
if (response.code && response.code === TerminateResponseCode.ProcessNotFound) {
|
|
3516
3516
|
this._notificationService.error(( localize(
|
|
3517
|
-
|
|
3517
|
+
12664,
|
|
3518
3518
|
"The launched process doesn't exist anymore. If the task spawned background tasks exiting VS Code might result in orphaned processes."
|
|
3519
3519
|
)));
|
|
3520
3520
|
} else {
|
|
3521
|
-
this._notificationService.error(( localize(
|
|
3521
|
+
this._notificationService.error(( localize(12665, "Failed to terminate running task")));
|
|
3522
3522
|
}
|
|
3523
3523
|
});
|
|
3524
3524
|
}
|
|
@@ -3541,8 +3541,8 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3541
3541
|
}
|
|
3542
3542
|
}
|
|
3543
3543
|
}
|
|
3544
|
-
const entry = await this._showQuickPick(activeTasks, ( localize(
|
|
3545
|
-
label: ( localize(
|
|
3544
|
+
const entry = await this._showQuickPick(activeTasks, ( localize(12666, "Select the task to restart")), {
|
|
3545
|
+
label: ( localize(12667, "No task to restart")),
|
|
3546
3546
|
task: null
|
|
3547
3547
|
}, false, true);
|
|
3548
3548
|
if (entry && entry.task) {
|
|
@@ -3557,7 +3557,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3557
3557
|
async _runRerunAllRunningTasksCommand() {
|
|
3558
3558
|
const activeTasks = await this.getActiveTasks();
|
|
3559
3559
|
if (activeTasks.length === 0) {
|
|
3560
|
-
this._notificationService.info(( localize(
|
|
3560
|
+
this._notificationService.info(( localize(12668, "No running tasks to restart")));
|
|
3561
3561
|
return;
|
|
3562
3562
|
}
|
|
3563
3563
|
const restartPromises = ( activeTasks.map(task => this._restart(task)));
|
|
@@ -3600,7 +3600,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3600
3600
|
let content;
|
|
3601
3601
|
if (!tasksExistInFile) {
|
|
3602
3602
|
const pickTemplateResult = await this._quickInputService.pick(getTemplates(), {
|
|
3603
|
-
placeHolder: ( localize(
|
|
3603
|
+
placeHolder: ( localize(12669, "Select a Task Template"))
|
|
3604
3604
|
});
|
|
3605
3605
|
if (!pickTemplateResult) {
|
|
3606
3606
|
return Promise.resolve(undefined);
|
|
@@ -3683,7 +3683,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3683
3683
|
getTaskDescription(task) {
|
|
3684
3684
|
let description;
|
|
3685
3685
|
if (task._source.kind === TaskSourceKind.User) {
|
|
3686
|
-
description = ( localize(
|
|
3686
|
+
description = ( localize(12670, "User"));
|
|
3687
3687
|
} else if (task._source.kind === TaskSourceKind.WorkspaceFile) {
|
|
3688
3688
|
description = task.getWorkspaceFileName();
|
|
3689
3689
|
} else if (this.needsFolderQualification()) {
|
|
@@ -3707,8 +3707,8 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3707
3707
|
const stats = ( this._contextService.getWorkspace().folders.map(folder => {
|
|
3708
3708
|
return this._fileService.stat(folder.toResource(".vscode/tasks.json")).then(stat => stat, () => undefined);
|
|
3709
3709
|
}));
|
|
3710
|
-
const createLabel = ( localize(
|
|
3711
|
-
const openLabel = ( localize(
|
|
3710
|
+
const createLabel = ( localize(12671, "Create tasks.json file from template"));
|
|
3711
|
+
const openLabel = ( localize(12672, "Open tasks.json file"));
|
|
3712
3712
|
const tokenSource = ( new CancellationTokenSource());
|
|
3713
3713
|
const cancellationToken = tokenSource.token;
|
|
3714
3714
|
const entries = Promise.all(stats).then(stats => {
|
|
@@ -3771,7 +3771,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3771
3771
|
return resolvedEntries;
|
|
3772
3772
|
});
|
|
3773
3773
|
this._quickInputService.pick(entriesWithSettings, {
|
|
3774
|
-
placeHolder: ( localize(
|
|
3774
|
+
placeHolder: ( localize(12673, "Select a task to configure"))
|
|
3775
3775
|
}, cancellationToken).then(async selection => {
|
|
3776
3776
|
if (cancellationToken.isCancellationRequested) {
|
|
3777
3777
|
const task = (await entries)[0];
|
|
@@ -3814,7 +3814,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3814
3814
|
for (const task of tasks) {
|
|
3815
3815
|
if (task === defaultBuildTask) {
|
|
3816
3816
|
const label = ( localize(
|
|
3817
|
-
|
|
3817
|
+
12674,
|
|
3818
3818
|
"{0} is already marked as the default build task",
|
|
3819
3819
|
TaskQuickPick.getTaskLabelWithIcon(task, task.getQualifiedLabel())
|
|
3820
3820
|
));
|
|
@@ -3843,7 +3843,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3843
3843
|
const tokenSource = ( new CancellationTokenSource());
|
|
3844
3844
|
const cancellationToken = tokenSource.token;
|
|
3845
3845
|
this._quickInputService.pick(entries, {
|
|
3846
|
-
placeHolder: ( localize(
|
|
3846
|
+
placeHolder: ( localize(12673, "Select a task to configure"))
|
|
3847
3847
|
}, cancellationToken).then(async entry => {
|
|
3848
3848
|
if (cancellationToken.isCancellationRequested) {
|
|
3849
3849
|
const task = (await entries)[0];
|
|
@@ -3874,7 +3874,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3874
3874
|
}
|
|
3875
3875
|
});
|
|
3876
3876
|
this._quickInputService.pick(entries, {
|
|
3877
|
-
placeHolder: ( localize(
|
|
3877
|
+
placeHolder: ( localize(12675, "Select the task to be used as the default build task"))
|
|
3878
3878
|
}).then(entry => {
|
|
3879
3879
|
const task = entry && Object.hasOwn(entry, "task") ? entry.task : undefined;
|
|
3880
3880
|
if ((task === undefined) || (task === null)) {
|
|
@@ -3923,7 +3923,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3923
3923
|
if (selectedTask) {
|
|
3924
3924
|
selectedEntry = {
|
|
3925
3925
|
label: ( localize(
|
|
3926
|
-
|
|
3926
|
+
12676,
|
|
3927
3927
|
"{0} is already marked as the default test task.",
|
|
3928
3928
|
selectedTask.getQualifiedLabel()
|
|
3929
3929
|
)),
|
|
@@ -3932,7 +3932,7 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3932
3932
|
};
|
|
3933
3933
|
}
|
|
3934
3934
|
this._showIgnoredFoldersMessage().then(() => {
|
|
3935
|
-
this._showQuickPick(tasks, ( localize(
|
|
3935
|
+
this._showQuickPick(tasks, ( localize(12677, "Select the task to be used as the default test task")), undefined, true, false, selectedEntry).then(entry => {
|
|
3936
3936
|
const task = entry && Object.hasOwn(entry, "task") ? entry.task : undefined;
|
|
3937
3937
|
if (!task) {
|
|
3938
3938
|
return;
|
|
@@ -3978,8 +3978,8 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
3978
3978
|
})) {
|
|
3979
3979
|
this._taskSystem.revealTask(activeTasks[0]);
|
|
3980
3980
|
} else {
|
|
3981
|
-
this._showQuickPick(activeTasksPromise, ( localize(
|
|
3982
|
-
label: ( localize(
|
|
3981
|
+
this._showQuickPick(activeTasksPromise, ( localize(12678, "Select the task to show its output")), {
|
|
3982
|
+
label: ( localize(12679, "No task is running")),
|
|
3983
3983
|
task: null
|
|
3984
3984
|
}, false, true).then(entry => {
|
|
3985
3985
|
const task = entry ? entry.task : undefined;
|
|
@@ -4131,13 +4131,13 @@ let AbstractTaskService = class AbstractTaskService extends Disposable {
|
|
|
4131
4131
|
}
|
|
4132
4132
|
this._updateSetup();
|
|
4133
4133
|
this._notificationService.prompt(Severity.Warning, fileDiffs.length === 1 ? ( localize(
|
|
4134
|
-
|
|
4134
|
+
12680,
|
|
4135
4135
|
"The deprecated tasks version 0.1.0 has been removed. Your tasks have been upgraded to version 2.0.0. Open the diff to review the upgrade."
|
|
4136
4136
|
)) : ( localize(
|
|
4137
|
-
|
|
4137
|
+
12681,
|
|
4138
4138
|
"The deprecated tasks version 0.1.0 has been removed. Your tasks have been upgraded to version 2.0.0. Open the diffs to review the upgrade."
|
|
4139
4139
|
)), [{
|
|
4140
|
-
label: fileDiffs.length === 1 ? ( localize(
|
|
4140
|
+
label: fileDiffs.length === 1 ? ( localize(12682, "Open diff")) : ( localize(12683, "Open diffs")),
|
|
4141
4141
|
run: async () => {
|
|
4142
4142
|
for (const upgrade of fileDiffs) {
|
|
4143
4143
|
await this._editorService.openEditor({
|