Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(task): Align task group validation with VS Code #13075

Merged
merged 3 commits into from
Nov 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
- [task] prevent task widget title from being changed by task process [#13003](https://github.com/eclipse-theia/theia/pull/13003)
- [vscode] added Notebook CodeActionKind [#13093](https://github.com/eclipse-theia/theia/pull/13093) - contributed on behalf of STMicroelectronics
- [vscode] added support to env.ondidChangeShell event [#13097](https://github.com/eclipse-theia/theia/pull/13097) - contributed on behalf of STMicroelectronics
- [task] support `isDefault: false` in task group definition [#13075](https://github.com/eclipse-theia/theia/pull/13075) - contributed on behalf of STMicroelectronics

## v1.43.0 - 10/26/2023

Expand Down
30 changes: 14 additions & 16 deletions packages/task/src/browser/task-schema-updater.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,15 +294,27 @@ const commandAndArgs = {
const group: IJSONSchema = {
oneOf: [
{
type: 'string'
type: 'string',
enum: ['build', 'test', 'none'],
enumDescriptions: [
'Marks the task as a build task accessible through the \'Run Build Task\' command.',
'Marks the task as a test task accessible through the \'Run Test Task\' command.',
'Assigns the task to no group'
]
},
{
type: 'object',
properties: {
kind: {
type: 'string',
default: 'none',
description: 'The task\'s execution group.'
description: 'The task\'s execution group.',
enum: ['build', 'test', 'none'],
enumDescriptions: [
'Marks the task as a build task accessible through the \'Run Build Task\' command.',
'Marks the task as a test task accessible through the \'Run Test Task\' command.',
'Assigns the task to no group'
]
},
isDefault: {
type: 'boolean',
Expand All @@ -312,20 +324,6 @@ const group: IJSONSchema = {
}
}
],
enum: [
{ kind: 'build', isDefault: true },
{ kind: 'test', isDefault: true },
'build',
'test',
'none'
],
enumDescriptions: [
'Marks the task as the default build task.',
'Marks the task as the default test task.',
'Marks the task as a build task accessible through the \'Run Build Task\' command.',
'Marks the task as a test task accessible through the \'Run Test Task\' command.',
'Assigns the task to no group'
],
// eslint-disable-next-line max-len
description: 'Defines to which execution group this task belongs to. It supports "build" to add it to the build group and "test" to add it to the test group.'
};
Expand Down
Loading