@tsslint/cli 1.0.2 → 1.0.4

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 (2) hide show
  1. package/index.js +9 -4
  2. package/package.json +4 -4
package/index.js CHANGED
@@ -73,18 +73,23 @@ const glob = require("glob");
73
73
  async function projectWorker(tsconfigOption) {
74
74
  const tsconfig = await getTsconfigPath(tsconfigOption);
75
75
  const configFile = ts.findConfigFile(path.dirname(tsconfig), ts.sys.fileExists, 'tsslint.config.ts');
76
- log.step(`Project: ${path.relative(process.cwd(), tsconfig)}, Config: ${configFile ? path.relative(process.cwd(), configFile) : undefined} (${parseCommonLine(tsconfig).fileNames.length} input files)`);
76
+ log.step(`Project: ${path.relative(process.cwd(), tsconfig)} (${parseCommonLine(tsconfig).fileNames.length} files)`);
77
77
  if (!configFile) {
78
78
  log.error('No tsslint.config.ts file found!');
79
79
  return;
80
80
  }
81
81
  if (!configs.has(configFile)) {
82
82
  try {
83
- configs.set(configFile, await build.buildConfigFile(configFile, ts.sys.createHash));
83
+ configs.set(configFile, await build.buildConfigFile(configFile, ts.sys.createHash, {
84
+ log: log.info,
85
+ warn: log.warn,
86
+ error: log.error,
87
+ }));
84
88
  }
85
89
  catch (err) {
86
90
  configs.set(configFile, undefined);
87
- console.error(err);
91
+ // @ts-ignore
92
+ log.error(err);
88
93
  }
89
94
  }
90
95
  const tsslintConfig = configs.get(configFile);
@@ -171,7 +176,7 @@ const glob = require("glob");
171
176
  }
172
177
  tsconfig = await text({
173
178
  message: 'Select the tsconfig project. (Use --project or --projects to skip this prompt.)',
174
- placeholder: shortTsconfig ? `${shortTsconfig} (${parseCommonLine(tsconfig).fileNames.length} input files)` : 'No tsconfig.json/jsconfig.json found, please enter the path to the tsconfig.json/jsconfig.json file.',
179
+ placeholder: shortTsconfig ? `${shortTsconfig} (${parseCommonLine(tsconfig).fileNames.length} files)` : 'No tsconfig.json/jsconfig.json found, please enter the path to the tsconfig.json/jsconfig.json file.',
175
180
  defaultValue: shortTsconfig,
176
181
  validate(value) {
177
182
  value ||= shortTsconfig;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tsslint/cli",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "license": "MIT",
5
5
  "bin": {
6
6
  "tsslint": "./bin/tsslint.js"
@@ -16,12 +16,12 @@
16
16
  },
17
17
  "dependencies": {
18
18
  "@clack/prompts": "^0.7.0",
19
- "@tsslint/config": "1.0.2",
20
- "@tsslint/core": "1.0.2",
19
+ "@tsslint/config": "1.0.4",
20
+ "@tsslint/core": "1.0.4",
21
21
  "glob": "^10.4.1"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "typescript": "*"
25
25
  },
26
- "gitHead": "e9bbdd4eba295de6bcb663e02c305f2b48893d6f"
26
+ "gitHead": "97aa785e584757ed01f65a5bd838c468b0240788"
27
27
  }