@aklinker1/check 2.3.1 → 2.4.0

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/README.md CHANGED
@@ -14,7 +14,7 @@ pnpm check --fix
14
14
  To enable checks for any of the following modules, just install them:
15
15
 
16
16
  ```sh
17
- pnpm i -D typescript oxlint prettier publint eslint markdownlint-cli @typescript/native-preview
17
+ pnpm i -D typescript oxlint prettier publint eslint markdownlint-cli @typescript/native-preview cspell
18
18
  ```
19
19
 
20
20
  ## Contributing
package/dist/cli.js CHANGED
@@ -1,7 +1,7 @@
1
- import { a as isCi, i as ALL_TOOLS, t as check } from "./src-35ZaX6Fv.js";
1
+ import { a as isCi, i as ALL_TOOLS, t as check } from "./src-BO05XkIX.js";
2
2
 
3
3
  //#region package.json
4
- var version = "2.3.1";
4
+ var version = "2.4.0";
5
5
 
6
6
  //#endregion
7
7
  //#region src/cli.ts
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- import { n as renderProblem, r as renderProblemGroup, t as check } from "./src-35ZaX6Fv.js";
1
+ import { n as renderProblem, r as renderProblemGroup, t as check } from "./src-BO05XkIX.js";
2
2
 
3
3
  export { check, renderProblem, renderProblemGroup };
@@ -144,6 +144,34 @@ const SPINNER_FRAMES = {
144
144
  error: [red("✗")]
145
145
  };
146
146
 
147
+ //#endregion
148
+ //#region src/tools/cspell.ts
149
+ const cspell = ({ root }) => {
150
+ const checkCmd = "cspell --no-progress --no-summary .";
151
+ return {
152
+ name: "CSpell",
153
+ packageName: "cspell",
154
+ check: () => execAndParse(checkCmd, root, parseOutput$7)
155
+ };
156
+ };
157
+ const NEWLINE_REGEX$6 = /\r?\n/;
158
+ const ERROR_REGEX$3 = /^(?<file>.+?):(?<line>[0-9]+):(?<column>[0-9]+)\s+-\s+(?<message>.*)$/;
159
+ const parseOutput$7 = ({ stdout }) => {
160
+ return stdout.split(NEWLINE_REGEX$6).reduce((acc, line) => {
161
+ const groups = ERROR_REGEX$3.exec(line)?.groups;
162
+ if (groups) acc.push({
163
+ file: groups.file,
164
+ kind: "error",
165
+ message: groups.message,
166
+ location: {
167
+ line: parseInt(groups.line, 10),
168
+ column: parseInt(groups.column, 10)
169
+ }
170
+ });
171
+ return acc;
172
+ }, []);
173
+ };
174
+
147
175
  //#endregion
148
176
  //#region src/tools/eslint.ts
149
177
  const eslint = ({ root }) => {
@@ -385,9 +413,10 @@ const parseOutput = ({ stdout }) => {
385
413
  //#endregion
386
414
  //#region src/tools/index.ts
387
415
  const ALL_TOOLS = [
388
- oxfmt,
416
+ cspell,
389
417
  eslint,
390
418
  markdownlint,
419
+ oxfmt,
391
420
  oxlint,
392
421
  prettier,
393
422
  publint,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aklinker1/check",
3
- "version": "2.3.1",
3
+ "version": "2.4.0",
4
4
  "keywords": [
5
5
  "check",
6
6
  "eslint",