Skip to content

Commit

Permalink
Include task 'label' in the generated task.json
Browse files Browse the repository at this point in the history
Issue: #8980

Signed-off-by: Alvaro Sanchez-Leon <alvaro.sanchez-leon@ericsson.com>
  • Loading branch information
alvsan09 committed Jan 26, 2021
1 parent 5d2dadb commit d32c003
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 3 additions & 0 deletions packages/task/src/browser/task-configurations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -359,6 +359,9 @@ export class TaskConfigurations implements Disposable {
if (task.group) {
customization.group = task.group;
}

customization.label = task.label;

return { ...customization };
}

Expand Down
6 changes: 5 additions & 1 deletion packages/task/src/browser/task-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1105,7 +1105,11 @@ export class TaskService implements TaskConfigurationClient {
* @param task The task to configure
*/
async configure(token: number, task: TaskConfiguration): Promise<void> {
await this.taskConfigurations.configure(token, task);
const taskConfiguration = Object.freeze({
...task,
label: this.taskNameResolver.resolve(task)
});
await this.taskConfigurations.configure(token, taskConfiguration);
}

protected isEventForThisClient(context: string | undefined): boolean {
Expand Down

0 comments on commit d32c003

Please sign in to comment.