Skip to content
This repository was archived by the owner on Nov 16, 2023. It is now read-only.

Commit d3a519c

Browse files
authored
Merge pull request #98 from EB-Forks/feat/support-configuring-package-manager
feat: Support configuring used package manager
2 parents 12a73aa + c2a3193 commit d3a519c

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

package.json

+10
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,16 @@
137137
"tslint.suppressWhileTypeErrorsPresent": {
138138
"type": "boolean",
139139
"description": "Always show rule failures as warnings, independent of the tslint configuration."
140+
},
141+
"tslint.packageManager": {
142+
"type": "string",
143+
"enum": [
144+
"npm",
145+
"pnpm",
146+
"yarn"
147+
],
148+
"default": "npm",
149+
"description": "The package manager you use to install node modules."
140150
}
141151
}
142152
}

src/index.ts

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ interface SynchronizedConfiguration {
1212
suppressWhileTypeErrorsPresent?: boolean;
1313
jsEnable?: boolean;
1414
exclude?: string | string[];
15+
packageManager?: 'npm' | 'pnpm' | 'yarn';
1516
}
1617

1718
export async function activate(context: vscode.ExtensionContext) {
@@ -61,6 +62,7 @@ function getConfiguration(): SynchronizedConfiguration {
6162
withConfigValue(config, outConfig, 'jsEnable');
6263
withConfigValue(config, outConfig, 'configFile');
6364
withConfigValue(config, outConfig, 'exclude');
65+
withConfigValue(config, outConfig, 'packageManager');
6466

6567
return outConfig;
6668
}

0 commit comments

Comments
 (0)