vscode-eslint 0.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/$shared/customMessages.ts +113 -0
- package/$shared/settings.ts +189 -0
- package/.CodeQL.yml +5 -0
- package/.azure-pipelines.yml +27 -0
- package/.github/commands.yml +127 -0
- package/.github/locker.yml +6 -0
- package/.github/needs_more_info.yml +6 -0
- package/.github/workflows/npm-publish.yml +53 -0
- package/.github/workflows/release-please.yml +22 -0
- package/.lsifrc.json +4 -0
- package/.vscode/launch.json +20 -0
- package/.vscode/settings.json +52 -0
- package/.vscode/spellright.dict +8 -0
- package/.vscode/tasks.json +39 -0
- package/.vscodeignore +23 -0
- package/CHANGELOG.md +524 -0
- package/License.txt +17 -0
- package/README.md +517 -0
- package/SECURITY.md +41 -0
- package/agents.md +36 -0
- package/bin/vscode-eslint.js +56 -0
- package/build/azure-pipelines/linux/build.yml +14 -0
- package/build/azure-pipelines/pre-release.yml +42 -0
- package/build/azure-pipelines/release.yml +45 -0
- package/build/azure-pipelines/win32/build.yml +14 -0
- package/build/bin/all.js +29 -0
- package/build/bin/linking.js +102 -0
- package/build/bin/symlink.js +35 -0
- package/client/.mocharc.json +6 -0
- package/client/agents.md +5 -0
- package/client/package-lock.json +176 -0
- package/client/package.json +29 -0
- package/client/src/client.ts +992 -0
- package/client/src/extension.ts +180 -0
- package/client/src/node-utils.ts +393 -0
- package/client/src/settings.ts +379 -0
- package/client/src/tasks.ts +186 -0
- package/client/src/tests/glob.test.ts +31 -0
- package/client/src/vscode-utils.ts +28 -0
- package/client/test/mocha.opts +3 -0
- package/client/tsconfig.json +20 -0
- package/client/webpack.config.js +25 -0
- package/contributing.md +19 -0
- package/esbuild.js +62 -0
- package/eslint.config.js +129 -0
- package/eslint_icon.png +0 -0
- package/history/settings_1_9_x.md +110 -0
- package/images/2_1_10/eslint-dialog.png +0 -0
- package/images/2_1_10/eslint-status.png +0 -0
- package/package-json-schema.json +9 -0
- package/package.json +686 -0
- package/playgrounds/7.0/.eslintignore +1 -0
- package/playgrounds/7.0/.eslintrc.json +71 -0
- package/playgrounds/7.0/.vscode/settings.json +85 -0
- package/playgrounds/7.0/app.js +12 -0
- package/playgrounds/7.0/build/.eslintignore +1 -0
- package/playgrounds/7.0/build/.eslintrc.json +30 -0
- package/playgrounds/7.0/build/build.js +11 -0
- package/playgrounds/7.0/jsconfig.json +5 -0
- package/playgrounds/7.0/package-lock.json +2133 -0
- package/playgrounds/7.0/package.json +10 -0
- package/playgrounds/7.0/readme.md +0 -0
- package/playgrounds/7.0/subDir/sub.js +11 -0
- package/playgrounds/7.0/subDir/test.jsx +10 -0
- package/playgrounds/7.0/test.js +11 -0
- package/playgrounds/7.0/test.sh +1 -0
- package/playgrounds/7.0/test.vue +33 -0
- package/playgrounds/7.0/test2.html +8 -0
- package/playgrounds/8.0/.eslintignore +1 -0
- package/playgrounds/8.0/.eslintrc.json +71 -0
- package/playgrounds/8.0/.vscode/settings.json +91 -0
- package/playgrounds/8.0/app.js +12 -0
- package/playgrounds/8.0/build/.eslintignore +1 -0
- package/playgrounds/8.0/build/.eslintrc.json +30 -0
- package/playgrounds/8.0/build/build.js +11 -0
- package/playgrounds/8.0/jsconfig.json +5 -0
- package/playgrounds/8.0/package-lock.json +2321 -0
- package/playgrounds/8.0/package.json +10 -0
- package/playgrounds/8.0/readme.md +17 -0
- package/playgrounds/8.0/subDir/sub.js +11 -0
- package/playgrounds/8.0/subDir/test.jsx +10 -0
- package/playgrounds/8.0/test.ipynb +49 -0
- package/playgrounds/8.0/test.js +3 -0
- package/playgrounds/8.0/test.sh +1 -0
- package/playgrounds/8.0/test.vue +33 -0
- package/playgrounds/8.0/test2.html +8 -0
- package/playgrounds/9.0/flat/.vscode/settings.json +3 -0
- package/playgrounds/9.0/flat/app.js +12 -0
- package/playgrounds/9.0/flat/dist/ignore.js +12 -0
- package/playgrounds/9.0/flat/eslint.config.js +61 -0
- package/playgrounds/9.0/flat/package-lock.json +1053 -0
- package/playgrounds/9.0/flat/package.json +9 -0
- package/playgrounds/9.0/rc/.eslintrc.json +57 -0
- package/playgrounds/9.0/rc/.vscode/settings.json +3 -0
- package/playgrounds/9.0/rc/app.js +12 -0
- package/playgrounds/9.0/rc/package-lock.json +1345 -0
- package/playgrounds/9.0/rc/package.json +9 -0
- package/playgrounds/flat-config/.vscode/settings.json +22 -0
- package/playgrounds/flat-config/app.js +12 -0
- package/playgrounds/flat-config/eslint.config.js +51 -0
- package/playgrounds/flat-config/package-lock.json +2733 -0
- package/playgrounds/flat-config/package.json +12 -0
- package/playgrounds/flat-config/sub/sub.js +2 -0
- package/playgrounds/flat-config/test.ts +7 -0
- package/playgrounds/flat-config/tsconfig.json +11 -0
- package/playgrounds/flat-config-fail/f1/app.js +12 -0
- package/playgrounds/flat-config-fail/f1/eslint.config.js +51 -0
- package/playgrounds/flat-config-fail/package-lock.json +1683 -0
- package/playgrounds/flat-config-fail/package.json +11 -0
- package/playgrounds/flat-config-mjs/.vscode/settings.json +21 -0
- package/playgrounds/flat-config-mjs/app.js +12 -0
- package/playgrounds/flat-config-mjs/eslint.config.mjs +53 -0
- package/playgrounds/flat-config-mjs/package-lock.json +2860 -0
- package/playgrounds/flat-config-mjs/package.json +11 -0
- package/playgrounds/flat-config-mjs/sub/sub.js +2 -0
- package/playgrounds/flat-config-mjs/test.ts +7 -0
- package/playgrounds/flat-config-mjs/tsconfig.json +11 -0
- package/playgrounds/load-eslint/.vscode/settings.json +21 -0
- package/playgrounds/load-eslint/app.js +12 -0
- package/playgrounds/load-eslint/eslint.config.js +51 -0
- package/playgrounds/load-eslint/package-lock.json +2860 -0
- package/playgrounds/load-eslint/package.json +11 -0
- package/playgrounds/load-eslint/sub/sub.js +2 -0
- package/playgrounds/load-eslint/test.ts +7 -0
- package/playgrounds/load-eslint/tsconfig.json +11 -0
- package/playgrounds/noLib/test.js +22 -0
- package/playgrounds/noWD/.vscode/settings.json +2 -0
- package/playgrounds/noWD/src/.eslintrc.json +18 -0
- package/playgrounds/noWD/src/package-lock.json +2812 -0
- package/playgrounds/noWD/src/package.json +12 -0
- package/playgrounds/noWD/src/test.js +3 -0
- package/playgrounds/notebooks/notebook.ipynb +7072 -0
- package/playgrounds/notebooks/notebook2.ipynb +20 -0
- package/playgrounds/testing.code-workspace +28 -0
- package/playgrounds/ts/.eslintrc.base.json +23 -0
- package/playgrounds/ts/.eslintrc.json +191 -0
- package/playgrounds/ts/.vscode/settings.json +12 -0
- package/playgrounds/ts/package-lock.json +2687 -0
- package/playgrounds/ts/package.json +11 -0
- package/playgrounds/ts/test copy.ts +4 -0
- package/playgrounds/ts/test.ipynb +49 -0
- package/playgrounds/ts/test.ts +4 -0
- package/playgrounds/ts/test.tsx +14 -0
- package/playgrounds/ts/tsconfig.json +100 -0
- package/server/agents.md +9 -0
- package/server/package-lock.json +93 -0
- package/server/package.json +32 -0
- package/server/src/diff.ts +1079 -0
- package/server/src/eslint.ts +1471 -0
- package/server/src/eslintServer.ts +865 -0
- package/server/src/is.ts +18 -0
- package/server/src/languageDefaults.ts +40 -0
- package/server/src/linkedMap.ts +448 -0
- package/server/src/paths.ts +128 -0
- package/server/src/thenable.d.ts +5 -0
- package/server/tsconfig.json +21 -0
- package/server/webpack.config.js +25 -0
- package/shared.webpack.config.js +59 -0
- package/tsconfig.base.json +9 -0
- package/tsconfig.json +21 -0
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
/* --------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
* ------------------------------------------------------------------------------------------ */
|
|
5
|
+
|
|
6
|
+
import { NotificationType, NotificationType0, RequestType, TextDocumentIdentifier } from 'vscode-languageserver-protocol';
|
|
7
|
+
|
|
8
|
+
export enum Status {
|
|
9
|
+
ok = 1,
|
|
10
|
+
warn = 2,
|
|
11
|
+
error = 3
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export type StatusParams = {
|
|
15
|
+
uri: string;
|
|
16
|
+
state: Status;
|
|
17
|
+
validationTime?: number;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The status notification is sent from the server to the client to
|
|
22
|
+
* inform the client about server status changes.
|
|
23
|
+
*/
|
|
24
|
+
export namespace StatusNotification {
|
|
25
|
+
export const method: 'eslint/status' = 'eslint/status';
|
|
26
|
+
export const type = new NotificationType<StatusParams>(method);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export type NoConfigParams = {
|
|
30
|
+
message: string;
|
|
31
|
+
document: TextDocumentIdentifier;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export type NoConfigResult = {
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* The NoConfigRequest is sent from the server to the client to inform
|
|
39
|
+
* the client that no eslint configuration file could be found when
|
|
40
|
+
* trying to lint a file.
|
|
41
|
+
*/
|
|
42
|
+
export namespace NoConfigRequest {
|
|
43
|
+
export const method: 'eslint/noConfig' = 'eslint/noConfig';
|
|
44
|
+
export const type = new RequestType<NoConfigParams, NoConfigResult, void>(method);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export type NoESLintLibraryParams = {
|
|
48
|
+
source: TextDocumentIdentifier;
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
export type NoESLintLibraryResult = {
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* The NoESLintLibraryRequest is sent from the server to the client to
|
|
56
|
+
* inform the client that no eslint library could be found when trying
|
|
57
|
+
* to lint a file.
|
|
58
|
+
*/
|
|
59
|
+
export namespace NoESLintLibraryRequest {
|
|
60
|
+
export const method: 'eslint/noLibrary' = 'eslint/noLibrary';
|
|
61
|
+
export const type = new RequestType<NoESLintLibraryParams, NoESLintLibraryResult, void>(method);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export type OpenESLintDocParams = {
|
|
65
|
+
url: string;
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
export type OpenESLintDocResult = {
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* The eslint/openDoc request is sent from the server to the client to
|
|
73
|
+
* ask the client to open the documentation URI for a given
|
|
74
|
+
* ESLint rule.
|
|
75
|
+
*/
|
|
76
|
+
export namespace OpenESLintDocRequest {
|
|
77
|
+
export const method: 'eslint/openDoc' = 'eslint/openDoc';
|
|
78
|
+
export const type = new RequestType<OpenESLintDocParams, OpenESLintDocResult, void>(method);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export type ProbeFailedParams = {
|
|
82
|
+
textDocument: TextDocumentIdentifier;
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* The eslint/probeFailed request is sent from the server to the client
|
|
87
|
+
* to tell the client the the lint probing for a certain document has
|
|
88
|
+
* failed and that there is no need to sync that document to the server
|
|
89
|
+
* anymore.
|
|
90
|
+
*/
|
|
91
|
+
export namespace ProbeFailedRequest {
|
|
92
|
+
export const method: 'eslint/probeFailed' = 'eslint/probeFailed';
|
|
93
|
+
export const type = new RequestType<ProbeFailedParams, void, void>(method);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* The eslint/showOutputChannel notification is sent from the server to
|
|
98
|
+
* the client to ask the client to reveal it's output channel.
|
|
99
|
+
*/
|
|
100
|
+
export namespace ShowOutputChannel {
|
|
101
|
+
export const method: 'eslint/showOutputChannel' = 'eslint/showOutputChannel';
|
|
102
|
+
export const type = new NotificationType0('eslint/showOutputChannel');
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* The eslint/exitCalled notification is sent from the server to the client
|
|
107
|
+
* to inform the client that a process.exit call on the server got intercepted.
|
|
108
|
+
* The call was very likely made by an ESLint plugin.
|
|
109
|
+
*/
|
|
110
|
+
export namespace ExitCalled {
|
|
111
|
+
export const method: 'eslint/exitCalled' = 'eslint/exitCalled';
|
|
112
|
+
export const type = new NotificationType<[number, string]>(method);
|
|
113
|
+
}
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
/* --------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
* ------------------------------------------------------------------------------------------ */
|
|
5
|
+
|
|
6
|
+
import {
|
|
7
|
+
WorkspaceFolder
|
|
8
|
+
} from 'vscode-languageserver-protocol';
|
|
9
|
+
|
|
10
|
+
namespace Is {
|
|
11
|
+
const toString = Object.prototype.toString;
|
|
12
|
+
|
|
13
|
+
export function boolean(value: any): value is boolean {
|
|
14
|
+
return value === true || value === false;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export function string(value: any): value is string {
|
|
18
|
+
return toString.call(value) === '[object String]';
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export enum Validate {
|
|
23
|
+
on = 'on',
|
|
24
|
+
off = 'off',
|
|
25
|
+
probe = 'probe'
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export type CodeActionSettings = {
|
|
29
|
+
disableRuleComment: {
|
|
30
|
+
enable: boolean;
|
|
31
|
+
location: 'separateLine' | 'sameLine';
|
|
32
|
+
commentStyle: 'line' | 'block';
|
|
33
|
+
};
|
|
34
|
+
showDocumentation: {
|
|
35
|
+
enable: boolean;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
export enum CodeActionsOnSaveMode {
|
|
40
|
+
all = 'all',
|
|
41
|
+
problems = 'problems'
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export namespace CodeActionsOnSaveMode {
|
|
45
|
+
export function from(value: string | undefined | null): CodeActionsOnSaveMode {
|
|
46
|
+
if (value === undefined || value === null || !Is.string(value)) {
|
|
47
|
+
return CodeActionsOnSaveMode.all;
|
|
48
|
+
}
|
|
49
|
+
switch(value.toLowerCase()) {
|
|
50
|
+
case CodeActionsOnSaveMode.problems:
|
|
51
|
+
return CodeActionsOnSaveMode.problems;
|
|
52
|
+
default:
|
|
53
|
+
return CodeActionsOnSaveMode.all;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export namespace CodeActionsOnSaveRules {
|
|
59
|
+
export function from(value: string[] | undefined | null): string[] | undefined {
|
|
60
|
+
if (value === undefined || value === null || !Array.isArray(value)) {
|
|
61
|
+
return undefined;
|
|
62
|
+
}
|
|
63
|
+
return value.filter(item => Is.string(item));
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export namespace CodeActionsOnSaveOptions {
|
|
68
|
+
export function from(value: object | undefined | null): ESLintOptions | undefined {
|
|
69
|
+
if (value === undefined || value === null || typeof value !== 'object') {
|
|
70
|
+
return undefined;
|
|
71
|
+
}
|
|
72
|
+
return value;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export type CodeActionsOnSaveSettings = {
|
|
77
|
+
mode: CodeActionsOnSaveMode;
|
|
78
|
+
rules?: string[];
|
|
79
|
+
options?: ESLintOptions;
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
export enum ESLintSeverity {
|
|
83
|
+
off = 'off',
|
|
84
|
+
warn = 'warn',
|
|
85
|
+
error = 'error'
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export namespace ESLintSeverity {
|
|
89
|
+
export function from(value: string | undefined | null): ESLintSeverity {
|
|
90
|
+
if (value === undefined || value === null) {
|
|
91
|
+
return ESLintSeverity.off;
|
|
92
|
+
}
|
|
93
|
+
switch (value.toLowerCase()) {
|
|
94
|
+
case ESLintSeverity.off:
|
|
95
|
+
return ESLintSeverity.off;
|
|
96
|
+
case ESLintSeverity.warn:
|
|
97
|
+
return ESLintSeverity.warn;
|
|
98
|
+
case ESLintSeverity.error:
|
|
99
|
+
return ESLintSeverity.error;
|
|
100
|
+
default:
|
|
101
|
+
return ESLintSeverity.off;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
export enum RuleSeverity {
|
|
107
|
+
// Original ESLint values
|
|
108
|
+
info = 'info',
|
|
109
|
+
warn = 'warn',
|
|
110
|
+
error = 'error',
|
|
111
|
+
off = 'off',
|
|
112
|
+
|
|
113
|
+
// Added severity override changes
|
|
114
|
+
default = 'default',
|
|
115
|
+
downgrade = 'downgrade',
|
|
116
|
+
upgrade = 'upgrade'
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
export type RuleCustomization = {
|
|
120
|
+
rule: string;
|
|
121
|
+
severity: RuleSeverity;
|
|
122
|
+
/** Only apply to autofixable rules */
|
|
123
|
+
fixable?: boolean;
|
|
124
|
+
};
|
|
125
|
+
|
|
126
|
+
export type RunValues = 'onType' | 'onSave';
|
|
127
|
+
|
|
128
|
+
export enum ModeEnum {
|
|
129
|
+
auto = 'auto',
|
|
130
|
+
location = 'location'
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export namespace ModeEnum {
|
|
134
|
+
export function is(value: string): value is ModeEnum {
|
|
135
|
+
return value === ModeEnum.auto || value === ModeEnum.location;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export type ModeItem = {
|
|
140
|
+
mode: ModeEnum;
|
|
141
|
+
};
|
|
142
|
+
|
|
143
|
+
export namespace ModeItem {
|
|
144
|
+
export function is(item: any): item is ModeItem {
|
|
145
|
+
const candidate = item as ModeItem;
|
|
146
|
+
return candidate && ModeEnum.is(candidate.mode);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export type DirectoryItem = {
|
|
151
|
+
directory: string;
|
|
152
|
+
'!cwd'?: boolean;
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
export namespace DirectoryItem {
|
|
156
|
+
export function is(item: any): item is DirectoryItem {
|
|
157
|
+
const candidate = item as DirectoryItem;
|
|
158
|
+
return candidate && Is.string(candidate.directory) && (Is.boolean(candidate['!cwd']) || candidate['!cwd'] === undefined);
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
export type PackageManagers = 'npm' | 'yarn' | 'pnpm';
|
|
163
|
+
|
|
164
|
+
export type ESLintOptions = object & { fixTypes?: string[] };
|
|
165
|
+
|
|
166
|
+
export type ConfigurationSettings = {
|
|
167
|
+
validate: Validate;
|
|
168
|
+
packageManager: PackageManagers;
|
|
169
|
+
useESLintClass: boolean;
|
|
170
|
+
useFlatConfig?: boolean | undefined;
|
|
171
|
+
useRealpaths: boolean;
|
|
172
|
+
experimental?: {
|
|
173
|
+
useFlatConfig: boolean;
|
|
174
|
+
};
|
|
175
|
+
codeAction: CodeActionSettings;
|
|
176
|
+
codeActionOnSave: CodeActionsOnSaveSettings;
|
|
177
|
+
format: boolean;
|
|
178
|
+
quiet: boolean;
|
|
179
|
+
onIgnoredFiles: ESLintSeverity;
|
|
180
|
+
options: ESLintOptions | undefined;
|
|
181
|
+
rulesCustomizations: RuleCustomization[];
|
|
182
|
+
run: RunValues;
|
|
183
|
+
problems: {
|
|
184
|
+
shortenToSingleLine: boolean;
|
|
185
|
+
};
|
|
186
|
+
nodePath: string | null;
|
|
187
|
+
workspaceFolder: WorkspaceFolder | undefined;
|
|
188
|
+
workingDirectory: ModeItem | DirectoryItem | undefined;
|
|
189
|
+
};
|
package/.CodeQL.yml
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
trigger:
|
|
2
|
+
batch: true
|
|
3
|
+
branches:
|
|
4
|
+
include:
|
|
5
|
+
- '*'
|
|
6
|
+
|
|
7
|
+
pr:
|
|
8
|
+
branches:
|
|
9
|
+
include:
|
|
10
|
+
- main
|
|
11
|
+
- release/*
|
|
12
|
+
|
|
13
|
+
variables:
|
|
14
|
+
Codeql.Enabled: true
|
|
15
|
+
|
|
16
|
+
jobs:
|
|
17
|
+
- job: Windows
|
|
18
|
+
pool:
|
|
19
|
+
vmImage: 'windows-latest'
|
|
20
|
+
steps:
|
|
21
|
+
- template: build/azure-pipelines/win32/build.yml
|
|
22
|
+
|
|
23
|
+
- job: Linux
|
|
24
|
+
pool:
|
|
25
|
+
vmImage: 'ubuntu-latest'
|
|
26
|
+
steps:
|
|
27
|
+
- template: build/azure-pipelines/linux/build.yml
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
{
|
|
2
|
+
perform: true,
|
|
3
|
+
commands: [
|
|
4
|
+
{
|
|
5
|
+
type: 'comment',
|
|
6
|
+
name: 'question',
|
|
7
|
+
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
|
8
|
+
action: 'updateLabels',
|
|
9
|
+
addLabel: '*question'
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
type: 'label',
|
|
13
|
+
name: '*question',
|
|
14
|
+
allowTriggerByBot: true,
|
|
15
|
+
action: 'close',
|
|
16
|
+
comment: "Please ask your question on [StackOverflow](https://aka.ms/vscodestackoverflow). We have a great community over [there](https://aka.ms/vscodestackoverflow). They have already answered thousands of questions and are happy to answer yours as well. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
type: 'label',
|
|
20
|
+
name: '*dev-question',
|
|
21
|
+
allowTriggerByBot: true,
|
|
22
|
+
action: 'close',
|
|
23
|
+
comment: "We have a great developer community [over on slack](https://aka.ms/vscode-dev-community) where extension authors help each other. This is a great place for you to ask questions and find support.\n\nHappy Coding!"
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
type: 'label',
|
|
27
|
+
name: '*extension-candidate',
|
|
28
|
+
allowTriggerByBot: true,
|
|
29
|
+
action: 'close',
|
|
30
|
+
comment: "We try to keep VS Code lean and we think the functionality you're asking for is great for a VS Code extension. Maybe you can already find one that suits you in the [VS Code Marketplace](https://aka.ms/vscodemarketplace). Just in case, in a few simple steps you can get started [writing your own extension](https://aka.ms/vscodewritingextensions). See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
type: 'label',
|
|
34
|
+
name: '*not-reproducible',
|
|
35
|
+
allowTriggerByBot: true,
|
|
36
|
+
action: 'close',
|
|
37
|
+
comment: "We closed this issue because we are unable to reproduce the problem with the steps you describe. Chances are we've already fixed your problem in a recent version of VS Code. If not, please ask us to reopen the issue and provide us with more detail. Our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines might help you with that.\n\nHappy Coding!"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
type: 'label',
|
|
41
|
+
name: '*out-of-scope',
|
|
42
|
+
allowTriggerByBot: true,
|
|
43
|
+
action: 'close',
|
|
44
|
+
comment: "We closed this issue because we don't plan to address it in the foreseeable future. You can find more detailed information about our decision-making process [here](https://aka.ms/vscode-out-of-scope). If you disagree and feel that this issue is crucial: We are happy to listen and to reconsider.\n\nIf you wonder what we are up to, please see our [roadmap](https://aka.ms/vscoderoadmap) and [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nThanks for your understanding and happy coding!"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
type: 'comment',
|
|
48
|
+
name: 'causedByExtension',
|
|
49
|
+
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
|
50
|
+
action: 'updateLabels',
|
|
51
|
+
addLabel: '*caused-by-extension'
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
type: 'label',
|
|
55
|
+
name: '*caused-by-extension',
|
|
56
|
+
allowTriggerByBot: true,
|
|
57
|
+
action: 'close',
|
|
58
|
+
comment: "This issue is caused by an extension, please file it with the repository (or contact) the extension has linked in its overview in VS Code or the [marketplace](https://aka.ms/vscodemarketplace) for VS Code. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
type: 'label',
|
|
62
|
+
name: '*as-designed',
|
|
63
|
+
allowTriggerByBot: true,
|
|
64
|
+
action: 'close',
|
|
65
|
+
comment: "The described behavior is how it is expected to work. If you disagree, please explain what is expected and what is not in more detail. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
type: 'label',
|
|
69
|
+
name: '*english-please',
|
|
70
|
+
allowTriggerByBot: true,
|
|
71
|
+
action: 'close',
|
|
72
|
+
comment: "This issue is being closed because its description is not in English, that makes it hard for us to work on it. Please open a new issue with an English description. You might find [Bing Translator](https://www.bing.com/translator) useful."
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
type: 'comment',
|
|
76
|
+
name: 'duplicate',
|
|
77
|
+
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
|
78
|
+
action: 'updateLabels',
|
|
79
|
+
addLabel: '*duplicate'
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
type: 'label',
|
|
83
|
+
name: '*duplicate',
|
|
84
|
+
allowTriggerByBot: true,
|
|
85
|
+
action: 'close',
|
|
86
|
+
comment: "Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for existing issues [here](https://aka.ms/vscodeissuesearch). See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
type: 'comment',
|
|
90
|
+
name: 'confirm',
|
|
91
|
+
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
|
92
|
+
action: 'updateLabels',
|
|
93
|
+
addLabel: 'confirmed',
|
|
94
|
+
removeLabel: 'confirmation-pending'
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
type: 'comment',
|
|
98
|
+
name: 'confirmationPending',
|
|
99
|
+
allowUsers: ['cleidigh', 'usernamehw'],
|
|
100
|
+
action: 'updateLabels',
|
|
101
|
+
addLabel: 'confirmation-pending',
|
|
102
|
+
removeLabel: 'confirmed'
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
type: 'comment',
|
|
106
|
+
name: 'findDuplicates',
|
|
107
|
+
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
|
108
|
+
action: 'comment',
|
|
109
|
+
comment: "Potential duplicates:\n${potentialDuplicates}"
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
type: 'comment',
|
|
113
|
+
name: 'needsMoreInfo',
|
|
114
|
+
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
|
115
|
+
action: 'updateLabels',
|
|
116
|
+
addLabel: 'needs more info',
|
|
117
|
+
comment: "Thanks for creating this issue! We figured it's missing some basic information or in some other way doesn't follow our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines. Please take the time to review these and update the issue.\n\nHappy Coding!"
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
type: 'comment',
|
|
121
|
+
name: 'a11ymas',
|
|
122
|
+
allowUsers: ['AccessibilityTestingTeam-TCS', 'dixitsonali95', 'Mohini78', 'ChitrarupaSharma', 'mspatil110', 'umasarath52', 'v-umnaik'],
|
|
123
|
+
action: 'updateLabels',
|
|
124
|
+
addLabel: 'a11ymas'
|
|
125
|
+
},
|
|
126
|
+
]
|
|
127
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
{
|
|
2
|
+
daysUntilClose: 7,
|
|
3
|
+
needsMoreInfoLabel: 'needs more info',
|
|
4
|
+
perform: true,
|
|
5
|
+
closeComment: "This issue has been closed automatically because it needs more information and has not had recent activity. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
|
6
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
name: Publish to npm
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types:
|
|
6
|
+
- published
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
|
|
11
|
+
concurrency:
|
|
12
|
+
group: npm-publish-${{ github.event.release.tag_name || github.ref_name }}
|
|
13
|
+
cancel-in-progress: true
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
publish:
|
|
17
|
+
runs-on: ubuntu-latest
|
|
18
|
+
steps:
|
|
19
|
+
- uses: actions/checkout@v4
|
|
20
|
+
with:
|
|
21
|
+
ref: ${{ github.event.release.tag_name || github.ref }}
|
|
22
|
+
|
|
23
|
+
- uses: actions/setup-node@v4
|
|
24
|
+
with:
|
|
25
|
+
node-version: 20
|
|
26
|
+
registry-url: https://registry.npmjs.org
|
|
27
|
+
|
|
28
|
+
- name: Install dependencies
|
|
29
|
+
run: npm ci
|
|
30
|
+
|
|
31
|
+
- name: Compile (if present)
|
|
32
|
+
run: npm run compile --if-present
|
|
33
|
+
|
|
34
|
+
- name: Run tests (if present)
|
|
35
|
+
run: |
|
|
36
|
+
if node -e "const scripts=require('./package.json').scripts||{}; process.exit(scripts.test ? 0 : 1)"; then
|
|
37
|
+
npm test
|
|
38
|
+
else
|
|
39
|
+
echo "No test script found. Skipping tests."
|
|
40
|
+
fi
|
|
41
|
+
|
|
42
|
+
- name: Run build (if present)
|
|
43
|
+
run: |
|
|
44
|
+
if node -e "const scripts=require('./package.json').scripts||{}; process.exit(scripts.build ? 0 : 1)"; then
|
|
45
|
+
npm run build
|
|
46
|
+
else
|
|
47
|
+
echo "No build script found. Skipping build."
|
|
48
|
+
fi
|
|
49
|
+
|
|
50
|
+
- name: Publish package
|
|
51
|
+
run: npm publish
|
|
52
|
+
env:
|
|
53
|
+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
name: Release Please
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags-ignore:
|
|
6
|
+
- '**'
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: write
|
|
10
|
+
pull-requests: write
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
release-please:
|
|
14
|
+
if: github.ref_name == github.event.repository.default_branch
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
steps:
|
|
17
|
+
- uses: googleapis/release-please-action@v4
|
|
18
|
+
with:
|
|
19
|
+
token: ${{ secrets.GITHUB_TOKEN }}
|
|
20
|
+
release-type: node
|
|
21
|
+
package-name: vscode-eslint
|
|
22
|
+
target-branch: ${{ github.event.repository.default_branch }}
|
package/.lsifrc.json
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
// A launch configuration that compiles the extension and then opens it inside a new window
|
|
2
|
+
{
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"configurations": [
|
|
5
|
+
{
|
|
6
|
+
"type": "extensionHost",
|
|
7
|
+
"request": "launch",
|
|
8
|
+
"name": "Launch Client",
|
|
9
|
+
"runtimeExecutable": "${execPath}",
|
|
10
|
+
"args": ["--extensionDevelopmentPath=${workspaceFolder}" ],
|
|
11
|
+
"sourceMaps": true,
|
|
12
|
+
"autoAttachChildProcesses": true,
|
|
13
|
+
"outFiles": [
|
|
14
|
+
"${workspaceFolder}/client/out/**/*.js",
|
|
15
|
+
"${workspaceFolder}/server/out/**/*.js"
|
|
16
|
+
],
|
|
17
|
+
"preLaunchTask": "npm: watch"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// Place your settings in this file to overwrite default and user settings.
|
|
2
|
+
{
|
|
3
|
+
"files.exclude": {
|
|
4
|
+
"out": false
|
|
5
|
+
},
|
|
6
|
+
"search.exclude": {
|
|
7
|
+
"out": true
|
|
8
|
+
},
|
|
9
|
+
"git.branchProtection": ["main"],
|
|
10
|
+
"files.trimTrailingWhitespace": true,
|
|
11
|
+
"editor.insertSpaces": false,
|
|
12
|
+
"editor.tabSize": 4,
|
|
13
|
+
"typescript.tsdk": "./node_modules/typescript/lib",
|
|
14
|
+
"typescript.tsc.autoDetect": "off",
|
|
15
|
+
"typescript.tsserver.trace": "off",
|
|
16
|
+
"typescript.tsserver.log": "off",
|
|
17
|
+
"editor.codeActionsOnSave": {
|
|
18
|
+
"source.fixAll.eslint": "explicit"
|
|
19
|
+
},
|
|
20
|
+
"eslint.enable": true,
|
|
21
|
+
"eslint.useESLintClass": true,
|
|
22
|
+
"eslint.useFlatConfig": true,
|
|
23
|
+
"eslint.codeActionsOnSave.rules": [
|
|
24
|
+
"@typescript-eslint/semi",
|
|
25
|
+
"@typescript-eslint/indent",
|
|
26
|
+
"!@typescript-eslint/*",
|
|
27
|
+
"*"
|
|
28
|
+
],
|
|
29
|
+
"eslint.workingDirectories": [
|
|
30
|
+
"./client",
|
|
31
|
+
"./server"
|
|
32
|
+
],
|
|
33
|
+
"eslint.trace.server": "messages",
|
|
34
|
+
"eslint.debug": false,
|
|
35
|
+
"eslint.lintTask.enable": false,
|
|
36
|
+
"eslint.format.enable": true,
|
|
37
|
+
"cSpell.words": [
|
|
38
|
+
"Affordance",
|
|
39
|
+
"Autofix",
|
|
40
|
+
"configurability",
|
|
41
|
+
"dbaeumer",
|
|
42
|
+
"eslintignore",
|
|
43
|
+
"eslintr",
|
|
44
|
+
"mydirectory",
|
|
45
|
+
"onsave",
|
|
46
|
+
"pnpm",
|
|
47
|
+
"uinteger",
|
|
48
|
+
"Undispatched",
|
|
49
|
+
"unregistration"
|
|
50
|
+
],
|
|
51
|
+
"task.allowAutomaticTasks": "on"
|
|
52
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
|
3
|
+
// for the documentation about the tasks.json format
|
|
4
|
+
"version": "2.0.0",
|
|
5
|
+
"tasks": [
|
|
6
|
+
{
|
|
7
|
+
"type": "npm",
|
|
8
|
+
"script": "watch",
|
|
9
|
+
"isBackground": true,
|
|
10
|
+
"group": {
|
|
11
|
+
"kind": "build",
|
|
12
|
+
"isDefault": true
|
|
13
|
+
},
|
|
14
|
+
"presentation": {
|
|
15
|
+
"reveal": "never",
|
|
16
|
+
"panel": "dedicated"
|
|
17
|
+
},
|
|
18
|
+
"problemMatcher": [
|
|
19
|
+
"$tsc-watch"
|
|
20
|
+
],
|
|
21
|
+
"runOptions": {
|
|
22
|
+
"runOn": "folderOpen"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"type": "npm",
|
|
27
|
+
"script": "compile",
|
|
28
|
+
"isBackground": false,
|
|
29
|
+
"group": "build",
|
|
30
|
+
"presentation": {
|
|
31
|
+
"reveal": "never",
|
|
32
|
+
"panel": "dedicated"
|
|
33
|
+
},
|
|
34
|
+
"problemMatcher": [
|
|
35
|
+
"$tsc"
|
|
36
|
+
]
|
|
37
|
+
}
|
|
38
|
+
]
|
|
39
|
+
}
|