@theia/task 1.77.0-next.99 → 1.78.0-next.0

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.
Files changed (252) hide show
  1. package/lib/browser/index.d.ts +6 -6
  2. package/lib/browser/index.d.ts.map +1 -1
  3. package/lib/browser/index.js +6 -9
  4. package/lib/browser/index.js.map +1 -1
  5. package/lib/browser/process/process-task-contribution.d.ts +2 -2
  6. package/lib/browser/process/process-task-contribution.d.ts.map +1 -1
  7. package/lib/browser/process/process-task-contribution.js +8 -12
  8. package/lib/browser/process/process-task-contribution.js.map +1 -1
  9. package/lib/browser/process/process-task-frontend-module.js +7 -10
  10. package/lib/browser/process/process-task-frontend-module.js.map +1 -1
  11. package/lib/browser/process/process-task-resolver.d.ts +4 -4
  12. package/lib/browser/process/process-task-resolver.d.ts.map +1 -1
  13. package/lib/browser/process/process-task-resolver.js +18 -24
  14. package/lib/browser/process/process-task-resolver.js.map +1 -1
  15. package/lib/browser/process/process-task-resolver.spec.js +49 -52
  16. package/lib/browser/process/process-task-resolver.spec.js.map +1 -1
  17. package/lib/browser/provided-task-configurations.d.ts +3 -3
  18. package/lib/browser/provided-task-configurations.d.ts.map +1 -1
  19. package/lib/browser/provided-task-configurations.js +18 -23
  20. package/lib/browser/provided-task-configurations.js.map +1 -1
  21. package/lib/browser/provided-task-configurations.spec.js +14 -16
  22. package/lib/browser/provided-task-configurations.spec.js.map +1 -1
  23. package/lib/browser/quick-open-task.d.ts +7 -7
  24. package/lib/browser/quick-open-task.d.ts.map +1 -1
  25. package/lib/browser/quick-open-task.js +160 -199
  26. package/lib/browser/quick-open-task.js.map +1 -1
  27. package/lib/browser/task-configuration-manager.d.ts +4 -4
  28. package/lib/browser/task-configuration-manager.d.ts.map +1 -1
  29. package/lib/browser/task-configuration-manager.js +62 -78
  30. package/lib/browser/task-configuration-manager.js.map +1 -1
  31. package/lib/browser/task-configuration-model.d.ts +1 -1
  32. package/lib/browser/task-configuration-model.d.ts.map +1 -1
  33. package/lib/browser/task-configuration-model.js +9 -13
  34. package/lib/browser/task-configuration-model.js.map +1 -1
  35. package/lib/browser/task-configurations.d.ts +6 -6
  36. package/lib/browser/task-configurations.d.ts.map +1 -1
  37. package/lib/browser/task-configurations.js +41 -55
  38. package/lib/browser/task-configurations.js.map +1 -1
  39. package/lib/browser/task-context-key-service.js +13 -21
  40. package/lib/browser/task-context-key-service.js.map +1 -1
  41. package/lib/browser/task-contribution.d.ts +1 -1
  42. package/lib/browser/task-contribution.d.ts.map +1 -1
  43. package/lib/browser/task-contribution.js +20 -27
  44. package/lib/browser/task-contribution.js.map +1 -1
  45. package/lib/browser/task-definition-registry.d.ts +1 -1
  46. package/lib/browser/task-definition-registry.d.ts.map +1 -1
  47. package/lib/browser/task-definition-registry.js +12 -15
  48. package/lib/browser/task-definition-registry.js.map +1 -1
  49. package/lib/browser/task-definition-registry.spec.js +20 -22
  50. package/lib/browser/task-definition-registry.spec.js.map +1 -1
  51. package/lib/browser/task-frontend-contribution.d.ts +5 -5
  52. package/lib/browser/task-frontend-contribution.d.ts.map +1 -1
  53. package/lib/browser/task-frontend-contribution.js +83 -106
  54. package/lib/browser/task-frontend-contribution.js.map +1 -1
  55. package/lib/browser/task-frontend-module.d.ts +1 -1
  56. package/lib/browser/task-frontend-module.d.ts.map +1 -1
  57. package/lib/browser/task-frontend-module.js +64 -66
  58. package/lib/browser/task-frontend-module.js.map +1 -1
  59. package/lib/browser/task-name-resolver.d.ts +3 -3
  60. package/lib/browser/task-name-resolver.d.ts.map +1 -1
  61. package/lib/browser/task-name-resolver.js +11 -16
  62. package/lib/browser/task-name-resolver.js.map +1 -1
  63. package/lib/browser/task-node.d.ts +1 -1
  64. package/lib/browser/task-node.d.ts.map +1 -1
  65. package/lib/browser/task-node.js +1 -5
  66. package/lib/browser/task-node.js.map +1 -1
  67. package/lib/browser/task-problem-matcher-registry.d.ts +2 -2
  68. package/lib/browser/task-problem-matcher-registry.d.ts.map +1 -1
  69. package/lib/browser/task-problem-matcher-registry.js +64 -72
  70. package/lib/browser/task-problem-matcher-registry.js.map +1 -1
  71. package/lib/browser/task-problem-pattern-registry.d.ts +1 -1
  72. package/lib/browser/task-problem-pattern-registry.d.ts.map +1 -1
  73. package/lib/browser/task-problem-pattern-registry.js +30 -37
  74. package/lib/browser/task-problem-pattern-registry.js.map +1 -1
  75. package/lib/browser/task-schema-updater.d.ts +3 -3
  76. package/lib/browser/task-schema-updater.d.ts.map +1 -1
  77. package/lib/browser/task-schema-updater.js +116 -127
  78. package/lib/browser/task-schema-updater.js.map +1 -1
  79. package/lib/browser/task-service.d.ts +19 -15
  80. package/lib/browser/task-service.d.ts.map +1 -1
  81. package/lib/browser/task-service.js +170 -203
  82. package/lib/browser/task-service.js.map +1 -1
  83. package/lib/browser/task-service.spec.js +21 -24
  84. package/lib/browser/task-service.spec.js.map +1 -1
  85. package/lib/browser/task-source-resolver.d.ts +2 -2
  86. package/lib/browser/task-source-resolver.d.ts.map +1 -1
  87. package/lib/browser/task-source-resolver.js +10 -14
  88. package/lib/browser/task-source-resolver.js.map +1 -1
  89. package/lib/browser/task-templates.js +10 -13
  90. package/lib/browser/task-templates.js.map +1 -1
  91. package/lib/browser/task-terminal-widget-manager.d.ts +2 -2
  92. package/lib/browser/task-terminal-widget-manager.d.ts.map +1 -1
  93. package/lib/browser/task-terminal-widget-manager.js +39 -50
  94. package/lib/browser/task-terminal-widget-manager.js.map +1 -1
  95. package/lib/browser/tasks-monaco-contribution.js +1 -4
  96. package/lib/browser/tasks-monaco-contribution.js.map +1 -1
  97. package/lib/common/index.d.ts +4 -4
  98. package/lib/common/index.d.ts.map +1 -1
  99. package/lib/common/index.js +4 -7
  100. package/lib/common/index.js.map +1 -1
  101. package/lib/common/problem-matcher-protocol.js +17 -20
  102. package/lib/common/problem-matcher-protocol.js.map +1 -1
  103. package/lib/common/process/task-protocol.d.ts +1 -1
  104. package/lib/common/process/task-protocol.d.ts.map +1 -1
  105. package/lib/common/process/task-protocol.js +6 -9
  106. package/lib/common/process/task-protocol.js.map +1 -1
  107. package/lib/common/task-common-module.js +3 -6
  108. package/lib/common/task-common-module.js.map +1 -1
  109. package/lib/common/task-preferences.js +10 -14
  110. package/lib/common/task-preferences.js.map +1 -1
  111. package/lib/common/task-protocol.d.ts +1 -1
  112. package/lib/common/task-protocol.d.ts.map +1 -1
  113. package/lib/common/task-protocol.js +15 -18
  114. package/lib/common/task-protocol.js.map +1 -1
  115. package/lib/common/task-util.js +2 -6
  116. package/lib/common/task-util.js.map +1 -1
  117. package/lib/common/task-watcher.d.ts +1 -1
  118. package/lib/common/task-watcher.d.ts.map +1 -1
  119. package/lib/common/task-watcher.js +12 -15
  120. package/lib/common/task-watcher.js.map +1 -1
  121. package/lib/node/custom/custom-task-runner-backend-module.js +14 -17
  122. package/lib/node/custom/custom-task-runner-backend-module.js.map +1 -1
  123. package/lib/node/custom/custom-task-runner-contribution.d.ts +2 -2
  124. package/lib/node/custom/custom-task-runner-contribution.d.ts.map +1 -1
  125. package/lib/node/custom/custom-task-runner-contribution.js +8 -12
  126. package/lib/node/custom/custom-task-runner-contribution.js.map +1 -1
  127. package/lib/node/custom/custom-task-runner.d.ts +4 -4
  128. package/lib/node/custom/custom-task-runner.d.ts.map +1 -1
  129. package/lib/node/custom/custom-task-runner.js +15 -21
  130. package/lib/node/custom/custom-task-runner.js.map +1 -1
  131. package/lib/node/custom/custom-task.d.ts +4 -4
  132. package/lib/node/custom/custom-task.d.ts.map +1 -1
  133. package/lib/node/custom/custom-task.js +15 -19
  134. package/lib/node/custom/custom-task.js.map +1 -1
  135. package/lib/node/index.d.ts +3 -3
  136. package/lib/node/index.d.ts.map +1 -1
  137. package/lib/node/index.js +3 -6
  138. package/lib/node/index.js.map +1 -1
  139. package/lib/node/process/process-task-runner-backend-module.js +14 -17
  140. package/lib/node/process/process-task-runner-backend-module.js.map +1 -1
  141. package/lib/node/process/process-task-runner-contribution.d.ts +2 -2
  142. package/lib/node/process/process-task-runner-contribution.d.ts.map +1 -1
  143. package/lib/node/process/process-task-runner-contribution.js +8 -12
  144. package/lib/node/process/process-task-runner-contribution.js.map +1 -1
  145. package/lib/node/process/process-task-runner.d.ts +5 -5
  146. package/lib/node/process/process-task-runner.d.ts.map +1 -1
  147. package/lib/node/process/process-task-runner.js +37 -44
  148. package/lib/node/process/process-task-runner.js.map +1 -1
  149. package/lib/node/process/process-task.d.ts +5 -5
  150. package/lib/node/process/process-task.d.ts.map +1 -1
  151. package/lib/node/process/process-task.js +16 -21
  152. package/lib/node/process/process-task.js.map +1 -1
  153. package/lib/node/process/process-task.spec.js +6 -8
  154. package/lib/node/process/process-task.spec.js.map +1 -1
  155. package/lib/node/task-abstract-line-matcher.d.ts +1 -1
  156. package/lib/node/task-abstract-line-matcher.d.ts.map +1 -1
  157. package/lib/node/task-abstract-line-matcher.js +28 -33
  158. package/lib/node/task-abstract-line-matcher.js.map +1 -1
  159. package/lib/node/task-backend-application-contribution.d.ts +1 -1
  160. package/lib/node/task-backend-application-contribution.d.ts.map +1 -1
  161. package/lib/node/task-backend-application-contribution.js +12 -17
  162. package/lib/node/task-backend-application-contribution.js.map +1 -1
  163. package/lib/node/task-backend-module.js +27 -29
  164. package/lib/node/task-backend-module.js.map +1 -1
  165. package/lib/node/task-line-matchers.d.ts +2 -2
  166. package/lib/node/task-line-matchers.d.ts.map +1 -1
  167. package/lib/node/task-line-matchers.js +3 -8
  168. package/lib/node/task-line-matchers.js.map +1 -1
  169. package/lib/node/task-manager.d.ts +2 -2
  170. package/lib/node/task-manager.d.ts.map +1 -1
  171. package/lib/node/task-manager.js +9 -13
  172. package/lib/node/task-manager.js.map +1 -1
  173. package/lib/node/task-problem-collector.d.ts +1 -1
  174. package/lib/node/task-problem-collector.d.ts.map +1 -1
  175. package/lib/node/task-problem-collector.js +9 -13
  176. package/lib/node/task-problem-collector.js.map +1 -1
  177. package/lib/node/task-problem-collector.spec.js +63 -65
  178. package/lib/node/task-problem-collector.spec.js.map +1 -1
  179. package/lib/node/task-runner-protocol.d.ts +2 -2
  180. package/lib/node/task-runner-protocol.d.ts.map +1 -1
  181. package/lib/node/task-runner-protocol.js +1 -4
  182. package/lib/node/task-runner-protocol.js.map +1 -1
  183. package/lib/node/task-runner.d.ts +2 -2
  184. package/lib/node/task-runner.d.ts.map +1 -1
  185. package/lib/node/task-runner.js +13 -20
  186. package/lib/node/task-runner.js.map +1 -1
  187. package/lib/node/task-server.d.ts +5 -5
  188. package/lib/node/task-server.d.ts.map +1 -1
  189. package/lib/node/task-server.js +21 -27
  190. package/lib/node/task-server.js.map +1 -1
  191. package/lib/node/task-server.slow-spec.js +58 -60
  192. package/lib/node/task-server.slow-spec.js.map +1 -1
  193. package/lib/node/task.d.ts +2 -2
  194. package/lib/node/task.d.ts.map +1 -1
  195. package/lib/node/task.js +12 -16
  196. package/lib/node/task.js.map +1 -1
  197. package/lib/node/test/task-test-container.js +28 -32
  198. package/lib/node/test/task-test-container.js.map +1 -1
  199. package/package.json +24 -13
  200. package/src/browser/index.ts +6 -6
  201. package/src/browser/process/process-task-contribution.ts +2 -2
  202. package/src/browser/process/process-task-frontend-module.ts +3 -3
  203. package/src/browser/process/process-task-resolver.spec.ts +4 -4
  204. package/src/browser/process/process-task-resolver.ts +4 -4
  205. package/src/browser/provided-task-configurations.spec.ts +4 -4
  206. package/src/browser/provided-task-configurations.ts +3 -3
  207. package/src/browser/quick-open-task.ts +8 -8
  208. package/src/browser/task-configuration-manager.ts +6 -6
  209. package/src/browser/task-configuration-model.ts +2 -2
  210. package/src/browser/task-configurations.ts +6 -6
  211. package/src/browser/task-contribution.ts +1 -1
  212. package/src/browser/task-definition-registry.spec.ts +2 -2
  213. package/src/browser/task-definition-registry.ts +1 -1
  214. package/src/browser/task-frontend-contribution.ts +5 -5
  215. package/src/browser/task-frontend-module.ts +22 -22
  216. package/src/browser/task-name-resolver.ts +3 -3
  217. package/src/browser/task-node.ts +1 -1
  218. package/src/browser/task-problem-matcher-registry.ts +2 -2
  219. package/src/browser/task-problem-pattern-registry.ts +1 -1
  220. package/src/browser/task-schema-updater.ts +5 -5
  221. package/src/browser/task-service.spec.ts +4 -4
  222. package/src/browser/task-service.ts +20 -16
  223. package/src/browser/task-source-resolver.ts +2 -2
  224. package/src/browser/task-terminal-widget-manager.ts +3 -3
  225. package/src/common/index.ts +4 -4
  226. package/src/common/process/task-protocol.ts +1 -1
  227. package/src/common/task-common-module.ts +1 -1
  228. package/src/common/task-protocol.ts +1 -1
  229. package/src/common/task-watcher.ts +1 -1
  230. package/src/node/custom/custom-task-runner-backend-module.ts +4 -4
  231. package/src/node/custom/custom-task-runner-contribution.ts +2 -2
  232. package/src/node/custom/custom-task-runner.ts +4 -4
  233. package/src/node/custom/custom-task.ts +4 -4
  234. package/src/node/index.ts +3 -3
  235. package/src/node/process/process-task-runner-backend-module.ts +4 -4
  236. package/src/node/process/process-task-runner-contribution.ts +2 -2
  237. package/src/node/process/process-task-runner.ts +5 -5
  238. package/src/node/process/process-task.spec.ts +1 -1
  239. package/src/node/process/process-task.ts +5 -5
  240. package/src/node/task-abstract-line-matcher.ts +1 -1
  241. package/src/node/task-backend-application-contribution.ts +1 -1
  242. package/src/node/task-backend-module.ts +9 -9
  243. package/src/node/task-line-matchers.ts +2 -2
  244. package/src/node/task-manager.ts +2 -2
  245. package/src/node/task-problem-collector.spec.ts +2 -2
  246. package/src/node/task-problem-collector.ts +3 -3
  247. package/src/node/task-runner-protocol.ts +2 -2
  248. package/src/node/task-runner.ts +2 -2
  249. package/src/node/task-server.slow-spec.ts +4 -4
  250. package/src/node/task-server.ts +8 -8
  251. package/src/node/task.ts +2 -2
  252. package/src/node/test/task-test-container.ts +1 -1
@@ -1,4 +1,3 @@
1
- "use strict";
2
1
  // *****************************************************************************
3
2
  // Copyright (C) 2017 Ericsson and others.
4
3
  //
@@ -14,50 +13,48 @@
14
13
  //
15
14
  // SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
16
15
  // *****************************************************************************
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.TaskService = exports.TaskEndedTypes = void 0;
19
- const tslib_1 = require("tslib");
20
- const browser_1 = require("@theia/core/lib/browser");
21
- const opener_service_1 = require("@theia/core/lib/browser/opener-service");
22
- const common_1 = require("@theia/core/lib/common");
23
- const message_service_1 = require("@theia/core/lib/common/message-service");
24
- const promise_util_1 = require("@theia/core/lib/common/promise-util");
25
- const quick_pick_service_1 = require("@theia/core/lib/common/quick-pick-service");
26
- const label_provider_1 = require("@theia/core/lib/browser/label-provider");
27
- const uri_1 = tslib_1.__importDefault(require("@theia/core/lib/common/uri"));
28
- const browser_2 = require("@theia/editor/lib/browser");
29
- const problem_manager_1 = require("@theia/markers/lib/browser/problem/problem-manager");
30
- const terminal_service_1 = require("@theia/terminal/lib/browser/base/terminal-service");
31
- const terminal_widget_impl_1 = require("@theia/terminal/lib/browser/terminal-widget-impl");
32
- const browser_3 = require("@theia/variable-resolver/lib/browser");
33
- const workspace_service_1 = require("@theia/workspace/lib/browser/workspace-service");
34
- const browser_4 = require("@theia/workspace/lib/browser");
35
- const inversify_1 = require("@theia/core/shared/inversify");
36
- const vscode_languageserver_protocol_1 = require("@theia/core/shared/vscode-languageserver-protocol");
37
- const common_2 = require("../common");
38
- const task_watcher_1 = require("../common/task-watcher");
39
- const provided_task_configurations_1 = require("./provided-task-configurations");
40
- const task_configurations_1 = require("./task-configurations");
41
- const task_contribution_1 = require("./task-contribution");
42
- const task_definition_registry_1 = require("./task-definition-registry");
43
- const task_name_resolver_1 = require("./task-name-resolver");
44
- const task_source_resolver_1 = require("./task-source-resolver");
45
- const task_problem_matcher_registry_1 = require("./task-problem-matcher-registry");
46
- const task_schema_updater_1 = require("./task-schema-updater");
47
- const task_configuration_manager_1 = require("./task-configuration-manager");
48
- const problem_widget_1 = require("@theia/markers/lib/browser/problem/problem-widget");
49
- const task_node_1 = require("./task-node");
50
- const monaco_workspace_1 = require("@theia/monaco/lib/browser/monaco-workspace");
51
- const task_terminal_widget_manager_1 = require("./task-terminal-widget-manager");
52
- const shell_terminal_protocol_1 = require("@theia/terminal/lib/common/shell-terminal-protocol");
53
- const async_mutex_1 = require("async-mutex");
54
- const task_context_key_service_1 = require("./task-context-key-service");
55
- const terminal_preferences_1 = require("@theia/terminal/lib/common/terminal-preferences");
56
- var TaskEndedTypes;
16
+ import { __decorate } from "tslib";
17
+ import { ApplicationShell, FrontendApplication, WidgetManager } from '@theia/core/lib/browser';
18
+ import { open, OpenerService } from '@theia/core/lib/browser/opener-service';
19
+ import { CommandService, ILogger, isCancelled, nls } from '@theia/core/lib/common';
20
+ import { MessageService } from '@theia/core/lib/common/message-service';
21
+ import { Deferred } from '@theia/core/lib/common/promise-util';
22
+ import { QuickPickService } from '@theia/core/lib/common/quick-pick-service';
23
+ import { LabelProvider } from '@theia/core/lib/browser/label-provider';
24
+ import URI from '@theia/core/lib/common/uri';
25
+ import { EditorManager } from '@theia/editor/lib/browser';
26
+ import { ProblemManager } from '@theia/markers/lib/browser/problem/problem-manager';
27
+ import { TerminalService } from '@theia/terminal/lib/browser/base/terminal-service';
28
+ import { nextTerminalCreationToken } from '@theia/terminal/lib/browser/terminal-widget-impl';
29
+ import { VariableResolverService } from '@theia/variable-resolver/lib/browser';
30
+ import { WorkspaceService } from '@theia/workspace/lib/browser/workspace-service';
31
+ import { WorkspaceTrustService } from '@theia/workspace/lib/browser';
32
+ import { inject, injectable, named, postConstruct } from '@theia/core/shared/inversify';
33
+ import { DiagnosticSeverity, Range } from '@theia/core/shared/vscode-languageserver-protocol';
34
+ import { ApplyToKind, DependsOrder, ProblemMatchData, RevealKind, TaskOutputPresentation, TaskServer, asVariableName } from '../common/index.js';
35
+ import { TaskWatcher } from '../common/task-watcher.js';
36
+ import { ProvidedTaskConfigurations } from './provided-task-configurations.js';
37
+ import { TaskConfigurations } from './task-configurations.js';
38
+ import { TaskResolverRegistry } from './task-contribution.js';
39
+ import { TaskDefinitionRegistry } from './task-definition-registry.js';
40
+ import { TaskNameResolver } from './task-name-resolver.js';
41
+ import { TaskSourceResolver } from './task-source-resolver.js';
42
+ import { ProblemMatcherRegistry } from './task-problem-matcher-registry.js';
43
+ import { TaskSchemaUpdater } from './task-schema-updater.js';
44
+ import { TaskConfigurationManager } from './task-configuration-manager.js';
45
+ import { PROBLEMS_WIDGET_ID } from '@theia/markers/lib/browser/problem/problem-widget';
46
+ import { TaskNode } from './task-node.js';
47
+ import { MonacoWorkspace } from '@theia/monaco/lib/browser/monaco-workspace';
48
+ import { TaskTerminalWidgetManager } from './task-terminal-widget-manager.js';
49
+ import { ShellTerminalServerProxy } from '@theia/terminal/lib/common/shell-terminal-protocol';
50
+ import { Mutex } from 'async-mutex';
51
+ import { TaskContextKeyService } from './task-context-key-service.js';
52
+ import { TerminalPreferences } from '@theia/terminal/lib/common/terminal-preferences';
53
+ export var TaskEndedTypes;
57
54
  (function (TaskEndedTypes) {
58
55
  TaskEndedTypes[TaskEndedTypes["TaskExited"] = 0] = "TaskExited";
59
56
  TaskEndedTypes[TaskEndedTypes["BackgroundTaskEnded"] = 1] = "BackgroundTaskEnded";
60
- })(TaskEndedTypes || (exports.TaskEndedTypes = TaskEndedTypes = {}));
57
+ })(TaskEndedTypes || (TaskEndedTypes = {}));
61
58
  let TaskService = class TaskService {
62
59
  constructor() {
63
60
  /**
@@ -66,14 +63,14 @@ let TaskService = class TaskService {
66
63
  this.lastTask = { resolvedTask: undefined, option: undefined };
67
64
  this.cachedRecentTasks = [];
68
65
  this.runningTasks = new Map();
69
- this.taskStartingLock = new async_mutex_1.Mutex();
66
+ this.taskStartingLock = new Mutex();
70
67
  }
71
68
  init() {
72
69
  this.getRunningTasks().then(tasks => tasks.forEach(task => {
73
70
  if (!this.runningTasks.has(task.taskId)) {
74
71
  this.runningTasks.set(task.taskId, {
75
- exitCode: new promise_util_1.Deferred(), terminateSignal: new promise_util_1.Deferred(),
76
- isBackgroundTaskEnded: new promise_util_1.Deferred()
72
+ exitCode: new Deferred(), terminateSignal: new Deferred(),
73
+ isBackgroundTaskEnded: new Deferred()
77
74
  });
78
75
  }
79
76
  }));
@@ -83,9 +80,9 @@ let TaskService = class TaskService {
83
80
  return;
84
81
  }
85
82
  this.runningTasks.set(event.taskId, {
86
- exitCode: new promise_util_1.Deferred(),
87
- terminateSignal: new promise_util_1.Deferred(),
88
- isBackgroundTaskEnded: new promise_util_1.Deferred()
83
+ exitCode: new Deferred(),
84
+ terminateSignal: new Deferred(),
85
+ isBackgroundTaskEnded: new Deferred()
89
86
  });
90
87
  });
91
88
  this.taskWatcher.onOutputProcessed(async (event) => {
@@ -100,14 +97,14 @@ let TaskService = class TaskService {
100
97
  return this.taskDefinitionRegistry.compareTasks(taskConfig, event.config);
101
98
  });
102
99
  const isTaskActiveAndOutputSilent = matchedRunningTaskInfo &&
103
- matchedRunningTaskInfo.config.presentation && matchedRunningTaskInfo.config.presentation.reveal === common_2.RevealKind.Silent;
100
+ matchedRunningTaskInfo.config.presentation && matchedRunningTaskInfo.config.presentation.reveal === RevealKind.Silent;
104
101
  event.problems.forEach(problem => {
105
102
  const existingMarkers = this.problemManager.findMarkers({ owner: problem.description.owner });
106
103
  const uris = new Set();
107
104
  existingMarkers.forEach(marker => uris.add(marker.uri));
108
- if (common_2.ProblemMatchData.is(problem) && problem.resource) {
105
+ if (ProblemMatchData.is(problem) && problem.resource) {
109
106
  // When task.presentation.reveal === RevealKind.Silent, put focus on the terminal only if it is an error
110
- if (isTaskActiveAndOutputSilent && problem.marker.severity === vscode_languageserver_protocol_1.DiagnosticSeverity.Error) {
107
+ if (isTaskActiveAndOutputSilent && problem.marker.severity === DiagnosticSeverity.Error) {
111
108
  const terminalId = matchedRunningTaskInfo.terminalId;
112
109
  if (terminalId) {
113
110
  const terminal = this.terminalService.getByTerminalId(terminalId);
@@ -124,9 +121,9 @@ let TaskService = class TaskService {
124
121
  }
125
122
  const uri = problem.resource.withScheme(problem.resource.scheme);
126
123
  const document = this.monacoWorkspace.getTextDocument(uri.toString());
127
- if (problem.description.applyTo === common_2.ApplyToKind.openDocuments && !!document ||
128
- problem.description.applyTo === common_2.ApplyToKind.closedDocuments && !document ||
129
- problem.description.applyTo === common_2.ApplyToKind.allDocuments) {
124
+ if (problem.description.applyTo === ApplyToKind.openDocuments && !!document ||
125
+ problem.description.applyTo === ApplyToKind.closedDocuments && !document ||
126
+ problem.description.applyTo === ApplyToKind.allDocuments) {
130
127
  if (uris.has(uri.toString())) {
131
128
  const newData = [
132
129
  ...existingMarkers
@@ -142,7 +139,7 @@ let TaskService = class TaskService {
142
139
  }
143
140
  }
144
141
  else { // should have received an event for finding the "background task begins" pattern
145
- uris.forEach(uriString => this.problemManager.setMarkers(new uri_1.default(uriString), problem.description.owner, []));
142
+ uris.forEach(uriString => this.problemManager.setMarkers(new URI(uriString), problem.description.owner, []));
146
143
  }
147
144
  });
148
145
  }
@@ -153,9 +150,9 @@ let TaskService = class TaskService {
153
150
  }
154
151
  if (!this.runningTasks.has(event.taskId)) {
155
152
  this.runningTasks.set(event.taskId, {
156
- exitCode: new promise_util_1.Deferred(),
157
- terminateSignal: new promise_util_1.Deferred(),
158
- isBackgroundTaskEnded: new promise_util_1.Deferred()
153
+ exitCode: new Deferred(),
154
+ terminateSignal: new Deferred(),
155
+ isBackgroundTaskEnded: new Deferred()
159
156
  });
160
157
  }
161
158
  this.runningTasks.get(event.taskId).isBackgroundTaskEnded.resolve(true);
@@ -167,9 +164,9 @@ let TaskService = class TaskService {
167
164
  }
168
165
  if (!this.runningTasks.has(event.taskId)) {
169
166
  this.runningTasks.set(event.taskId, {
170
- exitCode: new promise_util_1.Deferred(),
171
- terminateSignal: new promise_util_1.Deferred(),
172
- isBackgroundTaskEnded: new promise_util_1.Deferred()
167
+ exitCode: new Deferred(),
168
+ terminateSignal: new Deferred(),
169
+ isBackgroundTaskEnded: new Deferred()
173
170
  });
174
171
  }
175
172
  this.runningTasks.get(event.taskId).exitCode.resolve(event.code);
@@ -180,7 +177,7 @@ let TaskService = class TaskService {
180
177
  if (event.code !== undefined) {
181
178
  if (event.code !== 0) {
182
179
  const eventTaskConfig = event.config;
183
- if (eventTaskConfig && eventTaskConfig.presentation && eventTaskConfig.presentation.reveal === common_2.RevealKind.Silent && event.terminalId) {
180
+ if (eventTaskConfig && eventTaskConfig.presentation && eventTaskConfig.presentation.reveal === RevealKind.Silent && event.terminalId) {
184
181
  const terminal = this.terminalService.getByTerminalId(event.terminalId);
185
182
  const focus = !!eventTaskConfig.presentation.focus;
186
183
  if (terminal) {
@@ -192,11 +189,11 @@ let TaskService = class TaskService {
192
189
  }
193
190
  }
194
191
  }
195
- this.messageService.error(common_1.nls.localize('theia/task/taskExitedWithCode', "Task '{0}' has exited with code {1}.", taskIdentifier, event.code));
192
+ this.messageService.error(nls.localize('theia/task/taskExitedWithCode', "Task '{0}' has exited with code {1}.", taskIdentifier, event.code));
196
193
  }
197
194
  }
198
195
  else if (event.signal !== undefined) {
199
- this.messageService.info(common_1.nls.localize('theia/task/taskTerminatedBySignal', "Task '{0}' was terminated by signal {1}.", taskIdentifier, event.signal));
196
+ this.messageService.info(nls.localize('theia/task/taskTerminatedBySignal', "Task '{0}' was terminated by signal {1}.", taskIdentifier, event.signal));
200
197
  }
201
198
  else {
202
199
  this.logger.error('Invalid TaskExitedEvent received, neither code nor signal is set.');
@@ -206,7 +203,7 @@ let TaskService = class TaskService {
206
203
  getTaskIdentifier(taskConfig) {
207
204
  const taskName = this.taskNameResolver.resolve(taskConfig);
208
205
  const sourceStrUri = this.taskSourceResolver.resolve(taskConfig);
209
- return `${taskName} (${this.labelProvider.getName(new uri_1.default(sourceStrUri))})`;
206
+ return `${taskName} (${this.labelProvider.getName(new URI(sourceStrUri))})`;
210
207
  }
211
208
  /**
212
209
  * Client should call this method to indicate that a new user-level action related to tasks has been started,
@@ -238,7 +235,7 @@ let TaskService = class TaskService {
238
235
  async getConfiguredTasks(token) {
239
236
  const invalidTaskConfig = this.taskConfigurations.getInvalidTaskConfigurations()[0];
240
237
  if (invalidTaskConfig) {
241
- const widget = await this.widgetManager.getOrCreateWidget(problem_widget_1.PROBLEMS_WIDGET_ID);
238
+ const widget = await this.widgetManager.getOrCreateWidget(PROBLEMS_WIDGET_ID);
242
239
  const isProblemsWidgetVisible = widget && widget.isVisible;
243
240
  const currentEditorUri = this.editorManager.currentEditor && this.editorManager.currentEditor.editor.getResourceUri();
244
241
  let isInvalidTaskConfigFileOpen = false;
@@ -248,9 +245,9 @@ let TaskService = class TaskService {
248
245
  isInvalidTaskConfigFileOpen = true;
249
246
  }
250
247
  }
251
- const warningMessage = common_1.nls.localize('theia/task/invalidTaskConfigs', 'Invalid task configurations are found. Open tasks.json and find details in the Problems view.');
248
+ const warningMessage = nls.localize('theia/task/invalidTaskConfigs', 'Invalid task configurations are found. Open tasks.json and find details in the Problems view.');
252
249
  if (!isProblemsWidgetVisible || !isInvalidTaskConfigFileOpen) {
253
- this.messageService.warn(warningMessage, common_1.nls.localizeByDefault('Open')).then(actionOpen => {
250
+ this.messageService.warn(warningMessage, nls.localizeByDefault('Open')).then(actionOpen => {
254
251
  if (actionOpen) {
255
252
  if (invalidTaskConfig && invalidTaskConfig._scope) {
256
253
  this.taskConfigurationManager.openConfiguration(invalidTaskConfig._scope);
@@ -396,7 +393,7 @@ let TaskService = class TaskService {
396
393
  // ask the user what s/he wants to use to parse the task output
397
394
  const items = this.getCustomizeProblemMatcherItems();
398
395
  const selected = await this.quickPickService.show(items, {
399
- placeholder: common_1.nls.localizeByDefault('Select for which kind of errors and warnings to scan the task output')
396
+ placeholder: nls.localizeByDefault('Select for which kind of errors and warnings to scan the task output')
400
397
  });
401
398
  if (selected && ('value' in selected)) {
402
399
  if (selected.value?.problemMatchers) {
@@ -412,7 +409,7 @@ let TaskService = class TaskService {
412
409
  this.updateTaskConfiguration(token, task, { problemMatcher: matcherNames });
413
410
  }
414
411
  else if (selected.value?.learnMore) { // user wants to learn more about parsing task output
415
- (0, opener_service_1.open)(this.openerService, new uri_1.default('https://code.visualstudio.com/docs/editor/tasks#_processing-task-output-with-problem-matchers'));
412
+ open(this.openerService, new URI('https://code.visualstudio.com/docs/editor/tasks#_processing-task-output-with-problem-matchers'));
416
413
  }
417
414
  // else, continue the task with no parser
418
415
  }
@@ -443,7 +440,7 @@ let TaskService = class TaskService {
443
440
  async runCompoundTask(token, task, option) {
444
441
  const tasks = await this.getWorkspaceTasks(token, task._scope);
445
442
  try {
446
- const rootNode = new task_node_1.TaskNode(task, [], []);
443
+ const rootNode = new TaskNode(task, [], []);
447
444
  this.detectDirectedAcyclicGraph(task, rootNode, tasks);
448
445
  }
449
446
  catch (error) {
@@ -473,14 +470,14 @@ let TaskService = class TaskService {
473
470
  const resolvedMatchers = await this.resolveProblemMatchers(dependentTask, taskCustomization);
474
471
  dependentTasks.push({ 'task': dependentTask, 'taskCustomization': taskCustomization, 'resolvedMatchers': resolvedMatchers });
475
472
  // In case the 'dependsOrder' is 'sequence'
476
- if (task.dependsOrder && task.dependsOrder === common_2.DependsOrder.Sequence) {
473
+ if (task.dependsOrder && task.dependsOrder === DependsOrder.Sequence) {
477
474
  await this.runTasksGraph(dependentTask, tasks, {
478
475
  customization: { ...taskCustomization, ...{ problemMatcher: resolvedMatchers } }
479
476
  });
480
477
  }
481
478
  }
482
479
  // In case the 'dependsOrder' is 'parallel'
483
- if (((!task.dependsOrder) || (task.dependsOrder && task.dependsOrder === common_2.DependsOrder.Parallel))) {
480
+ if (((!task.dependsOrder) || (task.dependsOrder && task.dependsOrder === DependsOrder.Parallel))) {
484
481
  const promises = dependentTasks.map(item => this.runTasksGraph(item.task, tasks, {
485
482
  customization: { ...item.taskCustomization, ...{ problemMatcher: item.resolvedMatchers } }
486
483
  }));
@@ -540,9 +537,9 @@ let TaskService = class TaskService {
540
537
  taskNode.parentsID.filter(t => this.taskDefinitionRegistry.compareTasks(childTaskConfiguration, t)).length > 0) {
541
538
  const fromNode = task.label;
542
539
  const toNode = childTaskConfiguration.label;
543
- throw new Error(common_1.nls.localize('theia/task/circularReferenceDetected', 'Circular reference detected: {0} --> {1}', fromNode, toNode));
540
+ throw new Error(nls.localize('theia/task/circularReferenceDetected', 'Circular reference detected: {0} --> {1}', fromNode, toNode));
544
541
  }
545
- const childNode = new task_node_1.TaskNode(childTaskConfiguration, [], Object.assign([], taskNode.parentsID));
542
+ const childNode = new TaskNode(childTaskConfiguration, [], Object.assign([], taskNode.parentsID));
546
543
  childNode.addParentDependency(taskNode.taskId);
547
544
  taskNode.addChildDependency(childNode);
548
545
  return { 'taskConfiguration': childTaskConfiguration, 'node': childNode };
@@ -555,7 +552,7 @@ let TaskService = class TaskService {
555
552
  * @returns the correct TaskConfiguration object which matches the taskIdentifier
556
553
  */
557
554
  getDependentTask(taskIdentifier, tasks) {
558
- const notEnoughDataError = common_1.nls.localize('theia/task/notEnoughDataInDependsOn', 'The information provided in the "dependsOn" is not enough for matching the correct task!');
555
+ const notEnoughDataError = nls.localize('theia/task/notEnoughDataInDependsOn', 'The information provided in the "dependsOn" is not enough for matching the correct task!');
559
556
  let currentTaskChildConfiguration;
560
557
  if (typeof (taskIdentifier) !== 'string') {
561
558
  // TaskIdentifier object does not support tasks of type 'shell' (The same behavior as in VS Code).
@@ -617,17 +614,17 @@ let TaskService = class TaskService {
617
614
  if (terminalId) {
618
615
  const terminal = this.terminalService.getByTerminalId(terminalId);
619
616
  if (terminal) {
620
- if (common_2.TaskOutputPresentation.shouldSetFocusToTerminal(task)) { // assign focus to the terminal if presentation.focus is true
617
+ if (TaskOutputPresentation.shouldSetFocusToTerminal(task)) { // assign focus to the terminal if presentation.focus is true
621
618
  this.terminalService.open(terminal, { mode: 'activate' });
622
619
  }
623
- else if (common_2.TaskOutputPresentation.shouldAlwaysRevealTerminal(task)) { // show the terminal but not assign focus
620
+ else if (TaskOutputPresentation.shouldAlwaysRevealTerminal(task)) { // show the terminal but not assign focus
624
621
  this.terminalService.open(terminal, { mode: 'reveal' });
625
622
  }
626
623
  }
627
624
  }
628
- const terminateTaskAction = common_1.nls.localizeByDefault('Terminate Task');
629
- const restartTaskAction = common_1.nls.localizeByDefault('Restart Running Task');
630
- const selectedAction = await this.messageService.info(common_1.nls.localizeByDefault('Task `{0}` is already running.', taskName), terminateTaskAction, restartTaskAction);
625
+ const terminateTaskAction = nls.localizeByDefault('Terminate Task');
626
+ const restartTaskAction = nls.localizeByDefault('Restart Running Task');
627
+ const selectedAction = await this.messageService.info(nls.localizeByDefault('Task \'{0}\' is already running.', taskName), terminateTaskAction, restartTaskAction);
631
628
  if (selectedAction === terminateTaskAction) {
632
629
  await this.terminateTask(matchedRunningTaskInfo);
633
630
  }
@@ -691,7 +688,7 @@ let TaskService = class TaskService {
691
688
  return this.runResolvedTask(taskToRun, option);
692
689
  }
693
690
  catch (error) {
694
- if ((0, common_1.isCancelled)(error)) {
691
+ if (isCancelled(error)) {
695
692
  return undefined;
696
693
  }
697
694
  const errMessage = `Error resolving task '${task.label}': ${error}`;
@@ -730,7 +727,7 @@ let TaskService = class TaskService {
730
727
  const taskCustomization = await this.getTaskCustomization(task);
731
728
  const resolvedMatchers = await this.resolveProblemMatchers(task, taskCustomization);
732
729
  try {
733
- const rootNode = new task_node_1.TaskNode(task, [], []);
730
+ const rootNode = new TaskNode(task, [], []);
734
731
  this.detectDirectedAcyclicGraph(task, rootNode, tasks);
735
732
  }
736
733
  catch (error) {
@@ -757,10 +754,10 @@ let TaskService = class TaskService {
757
754
  async updateTaskConfiguration(token, task, update) {
758
755
  if (update.problemMatcher) {
759
756
  if (Array.isArray(update.problemMatcher)) {
760
- update.problemMatcher.forEach((_name, index) => update.problemMatcher[index] = (0, common_2.asVariableName)(update.problemMatcher[index]));
757
+ update.problemMatcher.forEach((_name, index) => update.problemMatcher[index] = asVariableName(update.problemMatcher[index]));
761
758
  }
762
759
  else {
763
- update.problemMatcher = (0, common_2.asVariableName)(update.problemMatcher);
760
+ update.problemMatcher = asVariableName(update.problemMatcher);
764
761
  }
765
762
  }
766
763
  this.taskConfigurations.updateTaskConfig(token, task, update);
@@ -789,7 +786,7 @@ let TaskService = class TaskService {
789
786
  const scope = task._scope || task._source;
790
787
  if (resolvedMatcher.filePrefix && scope) {
791
788
  const options = {
792
- context: new uri_1.default(scope).withScheme('file'),
789
+ context: new URI(scope).withScheme('file'),
793
790
  configurationSection: 'tasks'
794
791
  };
795
792
  const resolvedPrefix = await this.variableResolverService.resolve(resolvedMatcher.filePrefix, options);
@@ -826,7 +823,7 @@ let TaskService = class TaskService {
826
823
  const existingMarkers = this.problemManager.findMarkers({ owner: matcher.owner });
827
824
  const uris = new Set();
828
825
  existingMarkers.forEach(marker => uris.add(marker.uri));
829
- uris.forEach(uriString => this.problemManager.setMarkers(new uri_1.default(uriString), matcher.owner, []));
826
+ uris.forEach(uriString => this.problemManager.setMarkers(new URI(uriString), matcher.owner, []));
830
827
  }
831
828
  }
832
829
  }
@@ -860,7 +857,7 @@ let TaskService = class TaskService {
860
857
  }
861
858
  catch (error) {
862
859
  this.logger.error(`Error launching task '${taskLabel}': ${error.message}`);
863
- this.messageService.error(common_1.nls.localize('theia/task/errorLaunchingTask', "Error launching task '{0}': {1}", taskLabel, error.message));
860
+ this.messageService.error(nls.localize('theia/task/errorLaunchingTask', "Error launching task '{0}': {1}", taskLabel, error.message));
864
861
  if (taskInfo && typeof taskInfo.terminalId === 'number') {
865
862
  this.shellTerminalServer.onAttachAttempted(taskInfo.terminalId);
866
863
  }
@@ -869,15 +866,15 @@ let TaskService = class TaskService {
869
866
  getCustomizeProblemMatcherItems() {
870
867
  const items = [];
871
868
  items.push({
872
- label: common_1.nls.localizeByDefault('Continue without scanning the task output'),
869
+ label: nls.localizeByDefault('Continue without scanning the task output'),
873
870
  value: { problemMatchers: undefined }
874
871
  });
875
872
  items.push({
876
- label: common_1.nls.localize('theia/task/neverScanTaskOutput', 'Never scan the task output'),
873
+ label: nls.localize('theia/task/neverScanTaskOutput', 'Never scan the task output'),
877
874
  value: { problemMatchers: [] }
878
875
  });
879
876
  items.push({
880
- label: common_1.nls.localizeByDefault('Learn more about scanning the task output'),
877
+ label: nls.localizeByDefault('Learn more about scanning the task output'),
881
878
  value: { problemMatchers: undefined, learnMore: true }
882
879
  });
883
880
  items.push({ type: 'separator', label: 'registered parsers' });
@@ -885,7 +882,7 @@ let TaskService = class TaskService {
885
882
  items.push(...registeredProblemMatchers.map(matcher => ({
886
883
  label: matcher.label,
887
884
  value: { problemMatchers: [matcher] },
888
- description: (0, common_2.asVariableName)(matcher.name)
885
+ description: asVariableName(matcher.name)
889
886
  })));
890
887
  return items;
891
888
  }
@@ -900,15 +897,15 @@ let TaskService = class TaskService {
900
897
  const startCharacter = this.editorManager.currentEditor.editor.selection.start.character;
901
898
  const endLine = this.editorManager.currentEditor.editor.selection.end.line;
902
899
  const endCharacter = this.editorManager.currentEditor.editor.selection.end.character;
903
- let selectedRange = vscode_languageserver_protocol_1.Range.create(startLine, startCharacter, endLine, endCharacter);
900
+ let selectedRange = Range.create(startLine, startCharacter, endLine, endCharacter);
904
901
  // if no text is selected, default to selecting entire line
905
902
  if (startLine === endLine && startCharacter === endCharacter) {
906
- selectedRange = vscode_languageserver_protocol_1.Range.create(startLine, 0, endLine + 1, 0);
903
+ selectedRange = Range.create(startLine, 0, endLine + 1, 0);
907
904
  }
908
905
  const selectedText = this.editorManager.currentEditor.editor.document.getText(selectedRange).trimRight() + '\n';
909
906
  let terminal = this.terminalService.lastUsedTerminal;
910
907
  if (!terminal || terminal.kind !== 'user' || (await terminal.hasChildProcesses())) {
911
- terminal = await this.terminalService.newTerminal({ created: (0, terminal_widget_impl_1.nextTerminalCreationToken)() });
908
+ terminal = await this.terminalService.newTerminal({ created: nextTerminalCreationToken() });
912
909
  await terminal.start();
913
910
  this.terminalService.open(terminal);
914
911
  }
@@ -919,11 +916,11 @@ let TaskService = class TaskService {
919
916
  if (taskInfo) {
920
917
  const terminalWidget = this.terminalService.getByTerminalId(terminalId);
921
918
  if (terminalWidget) {
922
- this.messageService.error(common_1.nls.localize('theia/task/taskAlreadyRunningInTerminal', 'Task is already running in terminal'));
919
+ this.messageService.error(nls.localize('theia/task/taskAlreadyRunningInTerminal', 'Task is already running in terminal'));
923
920
  return this.terminalService.open(terminalWidget, { mode: 'activate' });
924
921
  }
925
- if (common_2.TaskOutputPresentation.shouldAlwaysRevealTerminal(taskInfo.config)) {
926
- if (common_2.TaskOutputPresentation.shouldSetFocusToTerminal(taskInfo.config)) { // assign focus to the terminal if presentation.focus is true
922
+ if (TaskOutputPresentation.shouldAlwaysRevealTerminal(taskInfo.config)) {
923
+ if (TaskOutputPresentation.shouldSetFocusToTerminal(taskInfo.config)) { // assign focus to the terminal if presentation.focus is true
927
924
  widgetOpenMode = 'activate';
928
925
  }
929
926
  else { // show the terminal but not assign focus
@@ -934,9 +931,9 @@ let TaskService = class TaskService {
934
931
  const { taskId } = taskInfo;
935
932
  // Create / find a terminal widget to display an execution output of a task that was launched as a command inside a shell.
936
933
  const widget = await this.taskTerminalWidgetManager.open({
937
- created: (0, terminal_widget_impl_1.nextTerminalCreationToken)(),
934
+ created: nextTerminalCreationToken(),
938
935
  id: this.getTerminalWidgetId(terminalId),
939
- title: common_1.nls.localizeByDefault('Task: {0}', taskInfo.config.label || common_1.nls.localize('theia/task/taskIdLabel', '#{0}', taskId)),
936
+ title: nls.localizeByDefault('Task: {0}', taskInfo.config.label || nls.localize('theia/task/taskIdLabel', '#{0}', taskId)),
940
937
  destroyTermOnClose: true,
941
938
  useServerTitle: false
942
939
  }, {
@@ -962,6 +959,10 @@ let TaskService = class TaskService {
962
959
  Object.assign(task, { label: this.taskNameResolver.resolve(task) });
963
960
  await this.taskConfigurations.configure(token, task);
964
961
  }
962
+ /**
963
+ * @param context the context of a task event, see {@link TaskInfo.ctx}
964
+ * @returns whether the event is for a task started by this client
965
+ */
965
966
  isEventForThisClient(context) {
966
967
  if (context === this.getContext()) {
967
968
  return true;
@@ -981,7 +982,7 @@ let TaskService = class TaskService {
981
982
  }
982
983
  catch (error) {
983
984
  this.logger.error(`Error killing task '${id}': ${error}`);
984
- this.messageService.error(common_1.nls.localize('theia/task/errorKillingTask', "Error killing task '{0}': {1}", id, error));
985
+ this.messageService.error(nls.localize('theia/task/errorKillingTask', "Error killing task '{0}': {1}", id, error));
985
986
  return;
986
987
  }
987
988
  this.logger.debug(`Task killed. Task id: ${id}`);
@@ -1021,139 +1022,105 @@ let TaskService = class TaskService {
1021
1022
  return trusted === true;
1022
1023
  }
1023
1024
  };
1024
- exports.TaskService = TaskService;
1025
- tslib_1.__decorate([
1026
- (0, inversify_1.inject)(browser_1.FrontendApplication),
1027
- tslib_1.__metadata("design:type", browser_1.FrontendApplication)
1025
+ __decorate([
1026
+ inject(FrontendApplication)
1028
1027
  ], TaskService.prototype, "app", void 0);
1029
- tslib_1.__decorate([
1030
- (0, inversify_1.inject)(browser_1.ApplicationShell),
1031
- tslib_1.__metadata("design:type", browser_1.ApplicationShell)
1028
+ __decorate([
1029
+ inject(ApplicationShell)
1032
1030
  ], TaskService.prototype, "shell", void 0);
1033
- tslib_1.__decorate([
1034
- (0, inversify_1.inject)(common_2.TaskServer),
1035
- tslib_1.__metadata("design:type", Object)
1031
+ __decorate([
1032
+ inject(TaskServer)
1036
1033
  ], TaskService.prototype, "taskServer", void 0);
1037
- tslib_1.__decorate([
1038
- (0, inversify_1.inject)(common_1.ILogger),
1039
- (0, inversify_1.named)('task:TaskService'),
1040
- tslib_1.__metadata("design:type", Object)
1034
+ __decorate([
1035
+ inject(ILogger),
1036
+ named('task:TaskService')
1041
1037
  ], TaskService.prototype, "logger", void 0);
1042
- tslib_1.__decorate([
1043
- (0, inversify_1.inject)(browser_1.WidgetManager),
1044
- tslib_1.__metadata("design:type", browser_1.WidgetManager)
1038
+ __decorate([
1039
+ inject(WidgetManager)
1045
1040
  ], TaskService.prototype, "widgetManager", void 0);
1046
- tslib_1.__decorate([
1047
- (0, inversify_1.inject)(task_watcher_1.TaskWatcher),
1048
- tslib_1.__metadata("design:type", task_watcher_1.TaskWatcher)
1041
+ __decorate([
1042
+ inject(TaskWatcher)
1049
1043
  ], TaskService.prototype, "taskWatcher", void 0);
1050
- tslib_1.__decorate([
1051
- (0, inversify_1.inject)(message_service_1.MessageService),
1052
- tslib_1.__metadata("design:type", message_service_1.MessageService)
1044
+ __decorate([
1045
+ inject(MessageService)
1053
1046
  ], TaskService.prototype, "messageService", void 0);
1054
- tslib_1.__decorate([
1055
- (0, inversify_1.inject)(workspace_service_1.WorkspaceService),
1056
- tslib_1.__metadata("design:type", workspace_service_1.WorkspaceService)
1047
+ __decorate([
1048
+ inject(WorkspaceService)
1057
1049
  ], TaskService.prototype, "workspaceService", void 0);
1058
- tslib_1.__decorate([
1059
- (0, inversify_1.inject)(task_configurations_1.TaskConfigurations),
1060
- tslib_1.__metadata("design:type", task_configurations_1.TaskConfigurations)
1050
+ __decorate([
1051
+ inject(TaskConfigurations)
1061
1052
  ], TaskService.prototype, "taskConfigurations", void 0);
1062
- tslib_1.__decorate([
1063
- (0, inversify_1.inject)(provided_task_configurations_1.ProvidedTaskConfigurations),
1064
- tslib_1.__metadata("design:type", provided_task_configurations_1.ProvidedTaskConfigurations)
1053
+ __decorate([
1054
+ inject(ProvidedTaskConfigurations)
1065
1055
  ], TaskService.prototype, "providedTaskConfigurations", void 0);
1066
- tslib_1.__decorate([
1067
- (0, inversify_1.inject)(browser_3.VariableResolverService),
1068
- tslib_1.__metadata("design:type", browser_3.VariableResolverService)
1056
+ __decorate([
1057
+ inject(VariableResolverService)
1069
1058
  ], TaskService.prototype, "variableResolverService", void 0);
1070
- tslib_1.__decorate([
1071
- (0, inversify_1.inject)(task_contribution_1.TaskResolverRegistry),
1072
- tslib_1.__metadata("design:type", task_contribution_1.TaskResolverRegistry)
1059
+ __decorate([
1060
+ inject(TaskResolverRegistry)
1073
1061
  ], TaskService.prototype, "taskResolverRegistry", void 0);
1074
- tslib_1.__decorate([
1075
- (0, inversify_1.inject)(terminal_service_1.TerminalService),
1076
- tslib_1.__metadata("design:type", Object)
1062
+ __decorate([
1063
+ inject(TerminalService)
1077
1064
  ], TaskService.prototype, "terminalService", void 0);
1078
- tslib_1.__decorate([
1079
- (0, inversify_1.inject)(browser_2.EditorManager),
1080
- tslib_1.__metadata("design:type", browser_2.EditorManager)
1065
+ __decorate([
1066
+ inject(EditorManager)
1081
1067
  ], TaskService.prototype, "editorManager", void 0);
1082
- tslib_1.__decorate([
1083
- (0, inversify_1.inject)(problem_manager_1.ProblemManager),
1084
- tslib_1.__metadata("design:type", problem_manager_1.ProblemManager)
1068
+ __decorate([
1069
+ inject(ProblemManager)
1085
1070
  ], TaskService.prototype, "problemManager", void 0);
1086
- tslib_1.__decorate([
1087
- (0, inversify_1.inject)(task_definition_registry_1.TaskDefinitionRegistry),
1088
- tslib_1.__metadata("design:type", task_definition_registry_1.TaskDefinitionRegistry)
1071
+ __decorate([
1072
+ inject(TaskDefinitionRegistry)
1089
1073
  ], TaskService.prototype, "taskDefinitionRegistry", void 0);
1090
- tslib_1.__decorate([
1091
- (0, inversify_1.inject)(task_problem_matcher_registry_1.ProblemMatcherRegistry),
1092
- tslib_1.__metadata("design:type", task_problem_matcher_registry_1.ProblemMatcherRegistry)
1074
+ __decorate([
1075
+ inject(ProblemMatcherRegistry)
1093
1076
  ], TaskService.prototype, "problemMatcherRegistry", void 0);
1094
- tslib_1.__decorate([
1095
- (0, inversify_1.inject)(quick_pick_service_1.QuickPickService),
1096
- tslib_1.__metadata("design:type", Object)
1077
+ __decorate([
1078
+ inject(QuickPickService)
1097
1079
  ], TaskService.prototype, "quickPickService", void 0);
1098
- tslib_1.__decorate([
1099
- (0, inversify_1.inject)(opener_service_1.OpenerService),
1100
- tslib_1.__metadata("design:type", Object)
1080
+ __decorate([
1081
+ inject(OpenerService)
1101
1082
  ], TaskService.prototype, "openerService", void 0);
1102
- tslib_1.__decorate([
1103
- (0, inversify_1.inject)(shell_terminal_protocol_1.ShellTerminalServerProxy),
1104
- tslib_1.__metadata("design:type", Object)
1083
+ __decorate([
1084
+ inject(ShellTerminalServerProxy)
1105
1085
  ], TaskService.prototype, "shellTerminalServer", void 0);
1106
- tslib_1.__decorate([
1107
- (0, inversify_1.inject)(task_name_resolver_1.TaskNameResolver),
1108
- tslib_1.__metadata("design:type", task_name_resolver_1.TaskNameResolver)
1086
+ __decorate([
1087
+ inject(TaskNameResolver)
1109
1088
  ], TaskService.prototype, "taskNameResolver", void 0);
1110
- tslib_1.__decorate([
1111
- (0, inversify_1.inject)(task_source_resolver_1.TaskSourceResolver),
1112
- tslib_1.__metadata("design:type", task_source_resolver_1.TaskSourceResolver)
1089
+ __decorate([
1090
+ inject(TaskSourceResolver)
1113
1091
  ], TaskService.prototype, "taskSourceResolver", void 0);
1114
- tslib_1.__decorate([
1115
- (0, inversify_1.inject)(task_schema_updater_1.TaskSchemaUpdater),
1116
- tslib_1.__metadata("design:type", task_schema_updater_1.TaskSchemaUpdater)
1092
+ __decorate([
1093
+ inject(TaskSchemaUpdater)
1117
1094
  ], TaskService.prototype, "taskSchemaUpdater", void 0);
1118
- tslib_1.__decorate([
1119
- (0, inversify_1.inject)(task_configuration_manager_1.TaskConfigurationManager),
1120
- tslib_1.__metadata("design:type", task_configuration_manager_1.TaskConfigurationManager)
1095
+ __decorate([
1096
+ inject(TaskConfigurationManager)
1121
1097
  ], TaskService.prototype, "taskConfigurationManager", void 0);
1122
- tslib_1.__decorate([
1123
- (0, inversify_1.inject)(common_1.CommandService),
1124
- tslib_1.__metadata("design:type", Object)
1098
+ __decorate([
1099
+ inject(CommandService)
1125
1100
  ], TaskService.prototype, "commands", void 0);
1126
- tslib_1.__decorate([
1127
- (0, inversify_1.inject)(label_provider_1.LabelProvider),
1128
- tslib_1.__metadata("design:type", label_provider_1.LabelProvider)
1101
+ __decorate([
1102
+ inject(LabelProvider)
1129
1103
  ], TaskService.prototype, "labelProvider", void 0);
1130
- tslib_1.__decorate([
1131
- (0, inversify_1.inject)(monaco_workspace_1.MonacoWorkspace),
1132
- tslib_1.__metadata("design:type", monaco_workspace_1.MonacoWorkspace)
1104
+ __decorate([
1105
+ inject(MonacoWorkspace)
1133
1106
  ], TaskService.prototype, "monacoWorkspace", void 0);
1134
- tslib_1.__decorate([
1135
- (0, inversify_1.inject)(task_terminal_widget_manager_1.TaskTerminalWidgetManager),
1136
- tslib_1.__metadata("design:type", task_terminal_widget_manager_1.TaskTerminalWidgetManager)
1107
+ __decorate([
1108
+ inject(TaskTerminalWidgetManager)
1137
1109
  ], TaskService.prototype, "taskTerminalWidgetManager", void 0);
1138
- tslib_1.__decorate([
1139
- (0, inversify_1.inject)(task_context_key_service_1.TaskContextKeyService),
1140
- tslib_1.__metadata("design:type", task_context_key_service_1.TaskContextKeyService)
1110
+ __decorate([
1111
+ inject(TaskContextKeyService)
1141
1112
  ], TaskService.prototype, "taskContextKeyService", void 0);
1142
- tslib_1.__decorate([
1143
- (0, inversify_1.inject)(browser_4.WorkspaceTrustService),
1144
- tslib_1.__metadata("design:type", browser_4.WorkspaceTrustService)
1113
+ __decorate([
1114
+ inject(WorkspaceTrustService)
1145
1115
  ], TaskService.prototype, "workspaceTrustService", void 0);
1146
- tslib_1.__decorate([
1147
- (0, inversify_1.inject)(terminal_preferences_1.TerminalPreferences),
1148
- tslib_1.__metadata("design:type", Object)
1116
+ __decorate([
1117
+ inject(TerminalPreferences)
1149
1118
  ], TaskService.prototype, "terminalPreferences", void 0);
1150
- tslib_1.__decorate([
1151
- (0, inversify_1.postConstruct)(),
1152
- tslib_1.__metadata("design:type", Function),
1153
- tslib_1.__metadata("design:paramtypes", []),
1154
- tslib_1.__metadata("design:returntype", void 0)
1119
+ __decorate([
1120
+ postConstruct()
1155
1121
  ], TaskService.prototype, "init", null);
1156
- exports.TaskService = TaskService = tslib_1.__decorate([
1157
- (0, inversify_1.injectable)()
1122
+ TaskService = __decorate([
1123
+ injectable()
1158
1124
  ], TaskService);
1125
+ export { TaskService };
1159
1126
  //# sourceMappingURL=task-service.js.map