@codingame/monaco-vscode-task-service-override 4.5.0 → 4.5.2
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/index.d.ts +1 -1
- package/package.json +2 -2
- package/vscode/src/vs/workbench/contrib/tasks/browser/abstractTaskService.js +348 -593
- package/vscode/src/vs/workbench/contrib/tasks/browser/runAutomaticTasks.js +20 -31
- package/vscode/src/vs/workbench/contrib/tasks/browser/task.contribution.js +73 -214
- package/vscode/src/vs/workbench/contrib/tasks/browser/taskQuickPick.js +37 -94
- package/vscode/src/vs/workbench/contrib/tasks/browser/taskService.js +4 -7
- package/vscode/src/vs/workbench/contrib/tasks/browser/taskTerminalStatus.js +18 -57
- package/vscode/src/vs/workbench/contrib/tasks/browser/tasksQuickAccess.js +15 -22
- package/vscode/src/vs/workbench/contrib/tasks/browser/terminalTaskSystem.js +178 -170
- package/vscode/src/vs/workbench/contrib/tasks/common/jsonSchemaCommon.js +67 -130
- package/vscode/src/vs/workbench/contrib/tasks/common/jsonSchema_v1.js +12 -35
- package/vscode/src/vs/workbench/contrib/tasks/common/jsonSchema_v2.js +138 -257
- package/vscode/src/vs/workbench/contrib/tasks/common/problemMatcher.js +173 -246
- package/vscode/src/vs/workbench/contrib/tasks/common/taskConfiguration.js +93 -95
- package/vscode/src/vs/workbench/contrib/tasks/common/taskTemplates.js +5 -20
- package/task.d.ts +0 -5
|
@@ -7,21 +7,22 @@ import { RunOnOptions as RunOnOptions$1, RevealKind, RevealProblemKind, PanelKin
|
|
|
7
7
|
import { TaskDefinitionRegistry } from 'vscode/vscode/vs/workbench/contrib/tasks/common/taskDefinitionRegistry';
|
|
8
8
|
import { ShellExecutionSupportedContext, ProcessExecutionSupportedContext } from 'vscode/vscode/vs/workbench/contrib/tasks/common/taskService';
|
|
9
9
|
|
|
10
|
+
const _moduleId = "vs/workbench/contrib/tasks/common/taskConfiguration";
|
|
10
11
|
var ITaskIdentifier;
|
|
11
|
-
( (function(ITaskIdentifier) {
|
|
12
|
+
( ((function(ITaskIdentifier) {
|
|
12
13
|
function is(value) {
|
|
13
14
|
const candidate = value;
|
|
14
15
|
return candidate !== undefined && isString(value.type);
|
|
15
16
|
}
|
|
16
17
|
ITaskIdentifier.is = is;
|
|
17
|
-
})(ITaskIdentifier || (ITaskIdentifier = {})));
|
|
18
|
+
})(ITaskIdentifier || (ITaskIdentifier = {}))));
|
|
18
19
|
var ProblemMatcherKind;
|
|
19
|
-
( (function(ProblemMatcherKind) {
|
|
20
|
+
( ((function(ProblemMatcherKind) {
|
|
20
21
|
ProblemMatcherKind[ProblemMatcherKind["Unknown"] = 0] = "Unknown";
|
|
21
22
|
ProblemMatcherKind[ProblemMatcherKind["String"] = 1] = "String";
|
|
22
23
|
ProblemMatcherKind[ProblemMatcherKind["ProblemMatcher"] = 2] = "ProblemMatcher";
|
|
23
24
|
ProblemMatcherKind[ProblemMatcherKind["Array"] = 3] = "Array";
|
|
24
|
-
})(ProblemMatcherKind || (ProblemMatcherKind = {})));
|
|
25
|
+
})(ProblemMatcherKind || (ProblemMatcherKind = {}))));
|
|
25
26
|
const EMPTY_ARRAY = [];
|
|
26
27
|
function assignProperty(target, source, key) {
|
|
27
28
|
const sourceAtKey = source[key];
|
|
@@ -144,7 +145,7 @@ function _freeze(target, properties) {
|
|
|
144
145
|
return target;
|
|
145
146
|
}
|
|
146
147
|
var RunOnOptions;
|
|
147
|
-
( (function(RunOnOptions) {
|
|
148
|
+
( ((function(RunOnOptions) {
|
|
148
149
|
function fromString(value) {
|
|
149
150
|
if (!value) {
|
|
150
151
|
return RunOnOptions$1.default;
|
|
@@ -158,9 +159,9 @@ var RunOnOptions;
|
|
|
158
159
|
}
|
|
159
160
|
}
|
|
160
161
|
RunOnOptions.fromString = fromString;
|
|
161
|
-
})(RunOnOptions || (RunOnOptions = {})));
|
|
162
|
+
})(RunOnOptions || (RunOnOptions = {}))));
|
|
162
163
|
var RunOptions;
|
|
163
|
-
( (function(RunOptions) {
|
|
164
|
+
( ((function(RunOptions) {
|
|
164
165
|
const properties = [{ property: 'reevaluateOnRerun' }, { property: 'runOn' }, { property: 'instanceLimit' }];
|
|
165
166
|
function fromConfiguration(value) {
|
|
166
167
|
return {
|
|
@@ -178,9 +179,9 @@ var RunOptions;
|
|
|
178
179
|
return _fillProperties(target, source, properties);
|
|
179
180
|
}
|
|
180
181
|
RunOptions.fillProperties = fillProperties;
|
|
181
|
-
})(RunOptions || (RunOptions = {})));
|
|
182
|
+
})(RunOptions || (RunOptions = {}))));
|
|
182
183
|
var ShellConfiguration;
|
|
183
|
-
( (function(ShellConfiguration) {
|
|
184
|
+
( ((function(ShellConfiguration) {
|
|
184
185
|
const properties = [{ property: 'executable' }, { property: 'args' }, { property: 'quoting' }];
|
|
185
186
|
function is(value) {
|
|
186
187
|
const candidate = value;
|
|
@@ -224,12 +225,14 @@ var ShellConfiguration;
|
|
|
224
225
|
if (!value) {
|
|
225
226
|
return undefined;
|
|
226
227
|
}
|
|
227
|
-
return (
|
|
228
|
+
return (
|
|
229
|
+
(Object.freeze(value))
|
|
230
|
+
);
|
|
228
231
|
}
|
|
229
232
|
ShellConfiguration.freeze = freeze;
|
|
230
|
-
})(ShellConfiguration || (ShellConfiguration = {})));
|
|
233
|
+
})(ShellConfiguration || (ShellConfiguration = {}))));
|
|
231
234
|
var CommandOptions;
|
|
232
|
-
( (function(CommandOptions) {
|
|
235
|
+
( ((function(CommandOptions) {
|
|
233
236
|
const properties = [{ property: 'cwd' }, { property: 'env' }, { property: 'shell', type: ShellConfiguration }];
|
|
234
237
|
const defaults = { cwd: '${workspaceFolder}' };
|
|
235
238
|
function from(options, context) {
|
|
@@ -240,8 +243,8 @@ var CommandOptions;
|
|
|
240
243
|
}
|
|
241
244
|
else {
|
|
242
245
|
context.taskLoadIssues.push(( localizeWithPath(
|
|
243
|
-
|
|
244
|
-
|
|
246
|
+
_moduleId,
|
|
247
|
+
0,
|
|
245
248
|
'Warning: options.cwd must be of type string. Ignoring value {0}\n',
|
|
246
249
|
options.cwd
|
|
247
250
|
)));
|
|
@@ -272,10 +275,10 @@ var CommandOptions;
|
|
|
272
275
|
else if (source.env !== undefined) {
|
|
273
276
|
const env = Object.create(null);
|
|
274
277
|
if (target.env !== undefined) {
|
|
275
|
-
( Object.keys(target.env)).forEach(key => env[key] = target.env[key]);
|
|
278
|
+
( (Object.keys(target.env))).forEach(key => env[key] = target.env[key]);
|
|
276
279
|
}
|
|
277
280
|
if (source.env !== undefined) {
|
|
278
|
-
( Object.keys(source.env)).forEach(key => env[key] = source.env[key]);
|
|
281
|
+
( (Object.keys(source.env))).forEach(key => env[key] = source.env[key]);
|
|
279
282
|
}
|
|
280
283
|
target.env = env;
|
|
281
284
|
}
|
|
@@ -295,11 +298,11 @@ var CommandOptions;
|
|
|
295
298
|
return _freeze(value, properties);
|
|
296
299
|
}
|
|
297
300
|
CommandOptions.freeze = freeze;
|
|
298
|
-
})(CommandOptions || (CommandOptions = {})));
|
|
301
|
+
})(CommandOptions || (CommandOptions = {}))));
|
|
299
302
|
var CommandConfiguration;
|
|
300
|
-
( (function(CommandConfiguration) {
|
|
303
|
+
( ((function(CommandConfiguration) {
|
|
301
304
|
let PresentationOptions;
|
|
302
|
-
( (function(PresentationOptions) {
|
|
305
|
+
( ((function(PresentationOptions) {
|
|
303
306
|
const properties = [{ property: 'echo' }, { property: 'reveal' }, { property: 'revealProblems' }, { property: 'focus' }, { property: 'panel' }, { property: 'showReuseMessage' }, { property: 'clear' }, { property: 'group' }, { property: 'close' }];
|
|
304
307
|
function from(config, context) {
|
|
305
308
|
let echo;
|
|
@@ -380,9 +383,9 @@ var CommandConfiguration;
|
|
|
380
383
|
PresentationOptions.isEmpty = isEmpty;
|
|
381
384
|
})(
|
|
382
385
|
PresentationOptions = CommandConfiguration.PresentationOptions || (CommandConfiguration.PresentationOptions = {})
|
|
383
|
-
));
|
|
386
|
+
)));
|
|
384
387
|
let ShellString;
|
|
385
|
-
( (function(ShellString) {
|
|
388
|
+
( ((function(ShellString) {
|
|
386
389
|
function from(value) {
|
|
387
390
|
if (value === undefined || value === null) {
|
|
388
391
|
return undefined;
|
|
@@ -408,7 +411,7 @@ var CommandConfiguration;
|
|
|
408
411
|
}
|
|
409
412
|
}
|
|
410
413
|
ShellString.from = from;
|
|
411
|
-
})(ShellString || (ShellString = {})));
|
|
414
|
+
})(ShellString || (ShellString = {}))));
|
|
412
415
|
const properties = [
|
|
413
416
|
{ property: 'runtime' }, { property: 'name' }, { property: 'options', type: CommandOptions },
|
|
414
417
|
{ property: 'args' }, { property: 'taskSelector' }, { property: 'suppressTaskName' },
|
|
@@ -461,8 +464,8 @@ var CommandConfiguration;
|
|
|
461
464
|
}
|
|
462
465
|
else {
|
|
463
466
|
context.taskLoadIssues.push(( localizeWithPath(
|
|
464
|
-
|
|
465
|
-
|
|
467
|
+
_moduleId,
|
|
468
|
+
1,
|
|
466
469
|
'Error: command argument must either be a string or a quoted string. Provided value is:\n{0}',
|
|
467
470
|
arg ? JSON.stringify(arg, undefined, 4) : 'undefined'
|
|
468
471
|
)));
|
|
@@ -475,8 +478,8 @@ var CommandConfiguration;
|
|
|
475
478
|
result.options.shell = ShellConfiguration.from(config.isShellCommand, context);
|
|
476
479
|
if (context.engine !== ExecutionEngine$1.Terminal) {
|
|
477
480
|
context.taskLoadIssues.push(( localizeWithPath(
|
|
478
|
-
|
|
479
|
-
|
|
481
|
+
_moduleId,
|
|
482
|
+
2,
|
|
480
483
|
'Warning: shell configuration is only supported when executing tasks in the terminal.'
|
|
481
484
|
)));
|
|
482
485
|
}
|
|
@@ -582,23 +585,23 @@ var CommandConfiguration;
|
|
|
582
585
|
return _freeze(value, properties);
|
|
583
586
|
}
|
|
584
587
|
CommandConfiguration.freeze = freeze;
|
|
585
|
-
})(CommandConfiguration || (CommandConfiguration = {})));
|
|
588
|
+
})(CommandConfiguration || (CommandConfiguration = {}))));
|
|
586
589
|
var ProblemMatcherConverter;
|
|
587
|
-
( (function(ProblemMatcherConverter) {
|
|
590
|
+
( ((function(ProblemMatcherConverter) {
|
|
588
591
|
function namedFrom(declares, context) {
|
|
589
592
|
const result = Object.create(null);
|
|
590
593
|
if (!Array.isArray(declares)) {
|
|
591
594
|
return result;
|
|
592
595
|
}
|
|
593
596
|
declares.forEach((value) => {
|
|
594
|
-
const namedProblemMatcher = (( new ProblemMatcherParser(context.problemReporter))).parse(value);
|
|
597
|
+
const namedProblemMatcher = (( (new ProblemMatcherParser(context.problemReporter)))).parse(value);
|
|
595
598
|
if (isNamedProblemMatcher(namedProblemMatcher)) {
|
|
596
599
|
result[namedProblemMatcher.name] = namedProblemMatcher;
|
|
597
600
|
}
|
|
598
601
|
else {
|
|
599
602
|
context.problemReporter.error(( localizeWithPath(
|
|
600
|
-
|
|
601
|
-
|
|
603
|
+
_moduleId,
|
|
604
|
+
3,
|
|
602
605
|
'Error: Problem Matcher in declare scope must have a name:\n{0}\n',
|
|
603
606
|
JSON.stringify(value, undefined, 4)
|
|
604
607
|
)));
|
|
@@ -641,8 +644,8 @@ var ProblemMatcherConverter;
|
|
|
641
644
|
const kind = getProblemMatcherKind(config);
|
|
642
645
|
if (kind === ProblemMatcherKind.Unknown) {
|
|
643
646
|
const error = ( localizeWithPath(
|
|
644
|
-
|
|
645
|
-
|
|
647
|
+
_moduleId,
|
|
648
|
+
4,
|
|
646
649
|
'Warning: the defined problem matcher is unknown. Supported types are string | ProblemMatcher | Array<string | ProblemMatcher>.\n{0}\n',
|
|
647
650
|
JSON.stringify(config, null, 4)
|
|
648
651
|
));
|
|
@@ -690,25 +693,20 @@ var ProblemMatcherConverter;
|
|
|
690
693
|
return { value: localProblemMatcher };
|
|
691
694
|
}
|
|
692
695
|
}
|
|
693
|
-
return { errors: [( localizeWithPath(
|
|
694
|
-
'vs/workbench/contrib/tasks/common/taskConfiguration',
|
|
695
|
-
'ConfigurationParser.invalidVariableReference',
|
|
696
|
-
'Error: Invalid problemMatcher reference: {0}\n',
|
|
697
|
-
value
|
|
698
|
-
))] };
|
|
696
|
+
return { errors: [( localizeWithPath(_moduleId, 5, 'Error: Invalid problemMatcher reference: {0}\n', value))] };
|
|
699
697
|
}
|
|
700
698
|
else {
|
|
701
699
|
const json = value;
|
|
702
|
-
return { value: ( new ProblemMatcherParser(context.problemReporter)).parse(json) };
|
|
700
|
+
return { value: ( (new ProblemMatcherParser(context.problemReporter))).parse(json) };
|
|
703
701
|
}
|
|
704
702
|
}
|
|
705
|
-
})(ProblemMatcherConverter || (ProblemMatcherConverter = {})));
|
|
703
|
+
})(ProblemMatcherConverter || (ProblemMatcherConverter = {}))));
|
|
706
704
|
const partialSource = {
|
|
707
705
|
label: 'Workspace',
|
|
708
706
|
config: undefined
|
|
709
707
|
};
|
|
710
708
|
var GroupKind;
|
|
711
|
-
( (function(GroupKind) {
|
|
709
|
+
( ((function(GroupKind) {
|
|
712
710
|
function from(external) {
|
|
713
711
|
if (external === undefined) {
|
|
714
712
|
return undefined;
|
|
@@ -737,9 +735,9 @@ var GroupKind;
|
|
|
737
735
|
};
|
|
738
736
|
}
|
|
739
737
|
GroupKind.to = to;
|
|
740
|
-
})(GroupKind || (GroupKind = {})));
|
|
738
|
+
})(GroupKind || (GroupKind = {}))));
|
|
741
739
|
var TaskDependency;
|
|
742
|
-
( (function(TaskDependency) {
|
|
740
|
+
( ((function(TaskDependency) {
|
|
743
741
|
function uriFromSource(context, source) {
|
|
744
742
|
switch (source) {
|
|
745
743
|
case TaskConfigSource.User: return USER_TASKS_GROUP_KEY;
|
|
@@ -762,9 +760,9 @@ var TaskDependency;
|
|
|
762
760
|
}
|
|
763
761
|
}
|
|
764
762
|
TaskDependency.from = from;
|
|
765
|
-
})(TaskDependency || (TaskDependency = {})));
|
|
763
|
+
})(TaskDependency || (TaskDependency = {}))));
|
|
766
764
|
var DependsOrder;
|
|
767
|
-
( (function(DependsOrder) {
|
|
765
|
+
( ((function(DependsOrder) {
|
|
768
766
|
function from(order) {
|
|
769
767
|
switch (order) {
|
|
770
768
|
case "sequence" :
|
|
@@ -775,9 +773,9 @@ var DependsOrder;
|
|
|
775
773
|
}
|
|
776
774
|
}
|
|
777
775
|
DependsOrder.from = from;
|
|
778
|
-
})(DependsOrder || (DependsOrder = {})));
|
|
776
|
+
})(DependsOrder || (DependsOrder = {}))));
|
|
779
777
|
var ConfigurationProperties;
|
|
780
|
-
( (function(ConfigurationProperties) {
|
|
778
|
+
( ((function(ConfigurationProperties) {
|
|
781
779
|
const properties = [
|
|
782
780
|
{ property: 'name' },
|
|
783
781
|
{ property: 'identifier' },
|
|
@@ -797,7 +795,7 @@ var ConfigurationProperties;
|
|
|
797
795
|
}
|
|
798
796
|
const result = {};
|
|
799
797
|
if (properties) {
|
|
800
|
-
for (const propertyName of ( Object.keys(properties))) {
|
|
798
|
+
for (const propertyName of ( (Object.keys(properties)))) {
|
|
801
799
|
if (external[propertyName] !== undefined) {
|
|
802
800
|
result[propertyName] = deepClone(external[propertyName]);
|
|
803
801
|
}
|
|
@@ -857,9 +855,9 @@ var ConfigurationProperties;
|
|
|
857
855
|
return _isEmpty(value, properties);
|
|
858
856
|
}
|
|
859
857
|
ConfigurationProperties.isEmpty = isEmpty;
|
|
860
|
-
})(ConfigurationProperties || (ConfigurationProperties = {})));
|
|
858
|
+
})(ConfigurationProperties || (ConfigurationProperties = {}))));
|
|
861
859
|
var ConfiguringTask;
|
|
862
|
-
( (function(ConfiguringTask) {
|
|
860
|
+
( ((function(ConfiguringTask) {
|
|
863
861
|
const grunt = 'grunt.';
|
|
864
862
|
const jake = 'jake.';
|
|
865
863
|
const gulp = 'gulp.';
|
|
@@ -873,8 +871,8 @@ var ConfiguringTask;
|
|
|
873
871
|
const customize = external.customize;
|
|
874
872
|
if (!type && !customize) {
|
|
875
873
|
context.problemReporter.error(( localizeWithPath(
|
|
876
|
-
|
|
877
|
-
|
|
874
|
+
_moduleId,
|
|
875
|
+
6,
|
|
878
876
|
'Error: tasks configuration must have a type property. The configuration will be ignored.\n{0}\n',
|
|
879
877
|
JSON.stringify(external, null, 4)
|
|
880
878
|
)));
|
|
@@ -883,8 +881,8 @@ var ConfiguringTask;
|
|
|
883
881
|
const typeDeclaration = type ? registry?.get?.(type) || TaskDefinitionRegistry.get(type) : undefined;
|
|
884
882
|
if (!typeDeclaration) {
|
|
885
883
|
const message = ( localizeWithPath(
|
|
886
|
-
|
|
887
|
-
|
|
884
|
+
_moduleId,
|
|
885
|
+
7,
|
|
888
886
|
'Error: there is no registered task type \'{0}\'. Did you miss installing an extension that provides a corresponding task provider?',
|
|
889
887
|
type
|
|
890
888
|
));
|
|
@@ -916,8 +914,8 @@ var ConfiguringTask;
|
|
|
916
914
|
}
|
|
917
915
|
if (identifier === undefined) {
|
|
918
916
|
context.problemReporter.error(( localizeWithPath(
|
|
919
|
-
|
|
920
|
-
|
|
917
|
+
_moduleId,
|
|
918
|
+
8,
|
|
921
919
|
'Error: the task configuration \'{0}\' is missing the required property \'type\'. The task configuration will be ignored.',
|
|
922
920
|
JSON.stringify(external, undefined, 0)
|
|
923
921
|
)));
|
|
@@ -926,8 +924,8 @@ var ConfiguringTask;
|
|
|
926
924
|
const taskIdentifier = TaskDefinition.createTaskIdentifier(identifier, context.problemReporter);
|
|
927
925
|
if (taskIdentifier === undefined) {
|
|
928
926
|
context.problemReporter.error(( localizeWithPath(
|
|
929
|
-
|
|
930
|
-
|
|
927
|
+
_moduleId,
|
|
928
|
+
9,
|
|
931
929
|
'Error: the task configuration \'{0}\' is using an unknown type. The task configuration will be ignored.',
|
|
932
930
|
JSON.stringify(external, undefined, 0)
|
|
933
931
|
)));
|
|
@@ -982,9 +980,9 @@ var ConfiguringTask;
|
|
|
982
980
|
return result;
|
|
983
981
|
}
|
|
984
982
|
ConfiguringTask.from = from;
|
|
985
|
-
})(ConfiguringTask || (ConfiguringTask = {})));
|
|
983
|
+
})(ConfiguringTask || (ConfiguringTask = {}))));
|
|
986
984
|
var CustomTask;
|
|
987
|
-
( (function(CustomTask) {
|
|
985
|
+
( ((function(CustomTask) {
|
|
988
986
|
function from(external, context, index, source) {
|
|
989
987
|
if (!external) {
|
|
990
988
|
return undefined;
|
|
@@ -995,8 +993,8 @@ var CustomTask;
|
|
|
995
993
|
}
|
|
996
994
|
if (type !== CUSTOMIZED_TASK_TYPE && type !== 'shell' && type !== 'process') {
|
|
997
995
|
context.problemReporter.error(( localizeWithPath(
|
|
998
|
-
|
|
999
|
-
|
|
996
|
+
_moduleId,
|
|
997
|
+
10,
|
|
1000
998
|
'Error: tasks is not declared as a custom task. The configuration will be ignored.\n{0}\n',
|
|
1001
999
|
JSON.stringify(external, null, 4)
|
|
1002
1000
|
)));
|
|
@@ -1008,8 +1006,8 @@ var CustomTask;
|
|
|
1008
1006
|
}
|
|
1009
1007
|
if (!taskName) {
|
|
1010
1008
|
context.problemReporter.error(( localizeWithPath(
|
|
1011
|
-
|
|
1012
|
-
|
|
1009
|
+
_moduleId,
|
|
1010
|
+
11,
|
|
1013
1011
|
'Error: a task must provide a label property. The task will be ignored.\n{0}\n',
|
|
1014
1012
|
JSON.stringify(external, null, 4)
|
|
1015
1013
|
)));
|
|
@@ -1123,9 +1121,9 @@ var CustomTask;
|
|
|
1123
1121
|
return result;
|
|
1124
1122
|
}
|
|
1125
1123
|
CustomTask.createCustomTask = createCustomTask;
|
|
1126
|
-
})(CustomTask || (CustomTask = {})));
|
|
1124
|
+
})(CustomTask || (CustomTask = {}))));
|
|
1127
1125
|
var TaskParser;
|
|
1128
|
-
( (function(TaskParser) {
|
|
1126
|
+
( ((function(TaskParser) {
|
|
1129
1127
|
function isCustomTask(value) {
|
|
1130
1128
|
const type = value.type;
|
|
1131
1129
|
const customize = value.customize;
|
|
@@ -1152,7 +1150,7 @@ var TaskParser;
|
|
|
1152
1150
|
typeNotSupported = true;
|
|
1153
1151
|
}
|
|
1154
1152
|
else if (!definition && external.type) {
|
|
1155
|
-
for (const key of ( Object.keys(builtinTypeContextMap))) {
|
|
1153
|
+
for (const key of ( (Object.keys(builtinTypeContextMap)))) {
|
|
1156
1154
|
if (external.type === key) {
|
|
1157
1155
|
typeNotSupported = !ShellExecutionSupportedContext.evaluate(context.contextKeyService.getContext(null));
|
|
1158
1156
|
break;
|
|
@@ -1161,8 +1159,8 @@ var TaskParser;
|
|
|
1161
1159
|
}
|
|
1162
1160
|
if (typeNotSupported) {
|
|
1163
1161
|
context.problemReporter.info(( localizeWithPath(
|
|
1164
|
-
|
|
1165
|
-
|
|
1162
|
+
_moduleId,
|
|
1163
|
+
12,
|
|
1166
1164
|
'Warning: {0} tasks are unavailable in the current environment.\n',
|
|
1167
1165
|
external.type
|
|
1168
1166
|
)));
|
|
@@ -1176,8 +1174,8 @@ var TaskParser;
|
|
|
1176
1174
|
if (schema2_0_0) {
|
|
1177
1175
|
if ((customTask.command === undefined || customTask.command.name === undefined) && (customTask.configurationProperties.dependsOn === undefined || customTask.configurationProperties.dependsOn.length === 0)) {
|
|
1178
1176
|
context.problemReporter.error(( localizeWithPath(
|
|
1179
|
-
|
|
1180
|
-
|
|
1177
|
+
_moduleId,
|
|
1178
|
+
13,
|
|
1181
1179
|
'Error: the task \'{0}\' neither specifies a command nor a dependsOn property. The task will be ignored. Its definition is:\n{1}',
|
|
1182
1180
|
customTask.configurationProperties.name,
|
|
1183
1181
|
JSON.stringify(external, undefined, 4)
|
|
@@ -1188,8 +1186,8 @@ var TaskParser;
|
|
|
1188
1186
|
else {
|
|
1189
1187
|
if (customTask.command === undefined || customTask.command.name === undefined) {
|
|
1190
1188
|
context.problemReporter.warn(( localizeWithPath(
|
|
1191
|
-
|
|
1192
|
-
|
|
1189
|
+
_moduleId,
|
|
1190
|
+
14,
|
|
1193
1191
|
'Error: the task \'{0}\' doesn\'t define a command. The task will be ignored. Its definition is:\n{1}',
|
|
1194
1192
|
customTask.configurationProperties.name,
|
|
1195
1193
|
JSON.stringify(external, undefined, 4)
|
|
@@ -1257,15 +1255,15 @@ var TaskParser;
|
|
|
1257
1255
|
newTarget.push(map[task.configurationProperties.name]);
|
|
1258
1256
|
delete map[task.configurationProperties.name];
|
|
1259
1257
|
});
|
|
1260
|
-
( Object.keys(map)).forEach(key => newTarget.push(map[key]));
|
|
1258
|
+
( (Object.keys(map))).forEach(key => newTarget.push(map[key]));
|
|
1261
1259
|
target = newTarget;
|
|
1262
1260
|
}
|
|
1263
1261
|
return target;
|
|
1264
1262
|
}
|
|
1265
1263
|
TaskParser.assignTasks = assignTasks;
|
|
1266
|
-
})(TaskParser || (TaskParser = {})));
|
|
1264
|
+
})(TaskParser || (TaskParser = {}))));
|
|
1267
1265
|
var Globals;
|
|
1268
|
-
( (function(Globals) {
|
|
1266
|
+
( ((function(Globals) {
|
|
1269
1267
|
function from(config, context) {
|
|
1270
1268
|
let result = fromBase(config, context);
|
|
1271
1269
|
let osGlobals = undefined;
|
|
@@ -1339,9 +1337,9 @@ var Globals;
|
|
|
1339
1337
|
}
|
|
1340
1338
|
}
|
|
1341
1339
|
Globals.freeze = freeze;
|
|
1342
|
-
})(Globals || (Globals = {})));
|
|
1340
|
+
})(Globals || (Globals = {}))));
|
|
1343
1341
|
var ExecutionEngine;
|
|
1344
|
-
( (function(ExecutionEngine) {
|
|
1342
|
+
( ((function(ExecutionEngine) {
|
|
1345
1343
|
function from(config) {
|
|
1346
1344
|
const runner = config.runner || config._runner;
|
|
1347
1345
|
let result;
|
|
@@ -1363,13 +1361,13 @@ var ExecutionEngine;
|
|
|
1363
1361
|
return ExecutionEngine$1.Terminal;
|
|
1364
1362
|
}
|
|
1365
1363
|
else {
|
|
1366
|
-
throw new Error('Shouldn\'t happen.');
|
|
1364
|
+
throw ( (new Error('Shouldn\'t happen.')));
|
|
1367
1365
|
}
|
|
1368
1366
|
}
|
|
1369
1367
|
ExecutionEngine.from = from;
|
|
1370
|
-
})(ExecutionEngine || (ExecutionEngine = {})));
|
|
1368
|
+
})(ExecutionEngine || (ExecutionEngine = {}))));
|
|
1371
1369
|
var JsonSchemaVersion;
|
|
1372
|
-
( (function(JsonSchemaVersion) {
|
|
1370
|
+
( ((function(JsonSchemaVersion) {
|
|
1373
1371
|
const _default = 2 ;
|
|
1374
1372
|
function from(config) {
|
|
1375
1373
|
const version = config.version;
|
|
@@ -1386,12 +1384,12 @@ var JsonSchemaVersion;
|
|
|
1386
1384
|
}
|
|
1387
1385
|
}
|
|
1388
1386
|
JsonSchemaVersion.from = from;
|
|
1389
|
-
})(JsonSchemaVersion || (JsonSchemaVersion = {})));
|
|
1387
|
+
})(JsonSchemaVersion || (JsonSchemaVersion = {}))));
|
|
1390
1388
|
class UUIDMap {
|
|
1391
1389
|
constructor(other) {
|
|
1392
1390
|
this.current = Object.create(null);
|
|
1393
1391
|
if (other) {
|
|
1394
|
-
for (const key of ( Object.keys(other.current))) {
|
|
1392
|
+
for (const key of ( (Object.keys(other.current)))) {
|
|
1395
1393
|
const value = other.current[key];
|
|
1396
1394
|
if (Array.isArray(value)) {
|
|
1397
1395
|
this.current[key] = value.slice();
|
|
@@ -1445,11 +1443,11 @@ class UUIDMap {
|
|
|
1445
1443
|
}
|
|
1446
1444
|
}
|
|
1447
1445
|
var TaskConfigSource;
|
|
1448
|
-
( (function(TaskConfigSource) {
|
|
1446
|
+
( ((function(TaskConfigSource) {
|
|
1449
1447
|
TaskConfigSource[TaskConfigSource["TasksJson"] = 0] = "TasksJson";
|
|
1450
1448
|
TaskConfigSource[TaskConfigSource["WorkspaceFile"] = 1] = "WorkspaceFile";
|
|
1451
1449
|
TaskConfigSource[TaskConfigSource["User"] = 2] = "User";
|
|
1452
|
-
})(TaskConfigSource || (TaskConfigSource = {})));
|
|
1450
|
+
})(TaskConfigSource || (TaskConfigSource = {}))));
|
|
1453
1451
|
class ConfigurationParser {
|
|
1454
1452
|
constructor(workspaceFolder, workspace, platform, problemReporter, uuidMap) {
|
|
1455
1453
|
this.workspaceFolder = workspaceFolder;
|
|
@@ -1507,8 +1505,8 @@ class ConfigurationParser {
|
|
|
1507
1505
|
taskContent.push(JSON.stringify(task, null, 4));
|
|
1508
1506
|
}
|
|
1509
1507
|
context.problemReporter.error(( localizeWithPath(
|
|
1510
|
-
|
|
1511
|
-
|
|
1508
|
+
_moduleId,
|
|
1509
|
+
15,
|
|
1512
1510
|
'Task version 2.0.0 doesn\'t support global OS specific tasks. Convert them to a task with a OS specific command. Affected tasks are:\n{0}',
|
|
1513
1511
|
taskContent.join('\n')
|
|
1514
1512
|
)));
|
|
@@ -1552,23 +1550,23 @@ class ConfigurationParser {
|
|
|
1552
1550
|
return result;
|
|
1553
1551
|
}
|
|
1554
1552
|
}
|
|
1555
|
-
const uuidMaps = ( new Map());
|
|
1556
|
-
const recentUuidMaps = ( new Map());
|
|
1553
|
+
const uuidMaps = ( (new Map()));
|
|
1554
|
+
const recentUuidMaps = ( (new Map()));
|
|
1557
1555
|
function parse(workspaceFolder, workspace, platform, configuration, logger, source, contextKeyService, isRecents = false) {
|
|
1558
1556
|
const recentOrOtherMaps = isRecents ? recentUuidMaps : uuidMaps;
|
|
1559
1557
|
let selectedUuidMaps = recentOrOtherMaps.get(source);
|
|
1560
1558
|
if (!selectedUuidMaps) {
|
|
1561
|
-
recentOrOtherMaps.set(source, ( new Map()));
|
|
1559
|
+
recentOrOtherMaps.set(source, ( (new Map())));
|
|
1562
1560
|
selectedUuidMaps = recentOrOtherMaps.get(source);
|
|
1563
1561
|
}
|
|
1564
|
-
let uuidMap = selectedUuidMaps.get(( workspaceFolder.uri.toString()));
|
|
1562
|
+
let uuidMap = selectedUuidMaps.get(( (workspaceFolder.uri.toString())));
|
|
1565
1563
|
if (!uuidMap) {
|
|
1566
|
-
uuidMap = ( new UUIDMap());
|
|
1567
|
-
selectedUuidMaps.set(( workspaceFolder.uri.toString()), uuidMap);
|
|
1564
|
+
uuidMap = ( (new UUIDMap()));
|
|
1565
|
+
selectedUuidMaps.set(( (workspaceFolder.uri.toString())), uuidMap);
|
|
1568
1566
|
}
|
|
1569
1567
|
try {
|
|
1570
1568
|
uuidMap.start();
|
|
1571
|
-
return (( new ConfigurationParser(workspaceFolder, workspace, platform, logger, uuidMap))).run(configuration, source, contextKeyService);
|
|
1569
|
+
return (( (new ConfigurationParser(workspaceFolder, workspace, platform, logger, uuidMap)))).run(configuration, source, contextKeyService);
|
|
1572
1570
|
}
|
|
1573
1571
|
finally {
|
|
1574
1572
|
uuidMap.finish();
|
|
@@ -1,15 +1,12 @@
|
|
|
1
1
|
import { localizeWithPath } from 'vscode/vscode/vs/nls';
|
|
2
2
|
|
|
3
|
+
const _moduleId = "vs/workbench/contrib/tasks/common/taskTemplates";
|
|
3
4
|
const dotnetBuild = {
|
|
4
5
|
id: 'dotnetCore',
|
|
5
6
|
label: '.NET Core',
|
|
6
7
|
sort: 'NET Core',
|
|
7
8
|
autoDetect: false,
|
|
8
|
-
description: ( localizeWithPath(
|
|
9
|
-
'vs/workbench/contrib/tasks/common/taskTemplates',
|
|
10
|
-
'dotnetCore',
|
|
11
|
-
'Executes .NET Core build command'
|
|
12
|
-
)),
|
|
9
|
+
description: ( localizeWithPath(_moduleId, 0, 'Executes .NET Core build command')),
|
|
13
10
|
content: [
|
|
14
11
|
'{',
|
|
15
12
|
'\t// See https://go.microsoft.com/fwlink/?LinkId=733558',
|
|
@@ -41,11 +38,7 @@ const msbuild = {
|
|
|
41
38
|
id: 'msbuild',
|
|
42
39
|
label: 'MSBuild',
|
|
43
40
|
autoDetect: false,
|
|
44
|
-
description: ( localizeWithPath(
|
|
45
|
-
'vs/workbench/contrib/tasks/common/taskTemplates',
|
|
46
|
-
'msbuild',
|
|
47
|
-
'Executes the build target'
|
|
48
|
-
)),
|
|
41
|
+
description: ( localizeWithPath(_moduleId, 1, 'Executes the build target')),
|
|
49
42
|
content: [
|
|
50
43
|
'{',
|
|
51
44
|
'\t// See https://go.microsoft.com/fwlink/?LinkId=733558',
|
|
@@ -79,11 +72,7 @@ const command = {
|
|
|
79
72
|
id: 'externalCommand',
|
|
80
73
|
label: 'Others',
|
|
81
74
|
autoDetect: false,
|
|
82
|
-
description: ( localizeWithPath(
|
|
83
|
-
'vs/workbench/contrib/tasks/common/taskTemplates',
|
|
84
|
-
'externalCommand',
|
|
85
|
-
'Example to run an arbitrary external command'
|
|
86
|
-
)),
|
|
75
|
+
description: ( localizeWithPath(_moduleId, 2, 'Example to run an arbitrary external command')),
|
|
87
76
|
content: [
|
|
88
77
|
'{',
|
|
89
78
|
'\t// See https://go.microsoft.com/fwlink/?LinkId=733558',
|
|
@@ -104,11 +93,7 @@ const maven = {
|
|
|
104
93
|
label: 'maven',
|
|
105
94
|
sort: 'MVN',
|
|
106
95
|
autoDetect: false,
|
|
107
|
-
description: ( localizeWithPath(
|
|
108
|
-
'vs/workbench/contrib/tasks/common/taskTemplates',
|
|
109
|
-
'Maven',
|
|
110
|
-
'Executes common maven commands'
|
|
111
|
-
)),
|
|
96
|
+
description: ( localizeWithPath(_moduleId, 3, 'Executes common maven commands')),
|
|
112
97
|
content: [
|
|
113
98
|
'{',
|
|
114
99
|
'\t// See https://go.microsoft.com/fwlink/?LinkId=733558',
|