@cldmv/fix-headers 1.3.5 → 1.3.7
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/package.json +5 -4
- package/src/constants.mjs +4 -2
- package/src/detectors/index.mjs +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cldmv/fix-headers",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.7",
|
|
4
4
|
"description": "Multi-language project header normalizer with auto-detection and override support.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./index.cjs",
|
|
@@ -31,7 +31,8 @@
|
|
|
31
31
|
"types:build": "tsc -p .configs/tsconfig.json --noCheck",
|
|
32
32
|
"types:check": "tsc -p .configs/tsconfig.json --noEmit",
|
|
33
33
|
"test:coverage": "vitest run --config .configs/vitest.config.mjs --coverage",
|
|
34
|
-
"cli": "node ./src/cli.mjs"
|
|
34
|
+
"cli": "node ./src/cli.mjs",
|
|
35
|
+
"build": "echo 'no build step - stopgap for CI coverage-badge; see tracking issue'"
|
|
35
36
|
},
|
|
36
37
|
"keywords": [
|
|
37
38
|
"headers",
|
|
@@ -75,9 +76,9 @@
|
|
|
75
76
|
"license": "Apache-2.0",
|
|
76
77
|
"sideEffects": false,
|
|
77
78
|
"devDependencies": {
|
|
78
|
-
"@types/node": "^
|
|
79
|
+
"@types/node": "^26.1.1",
|
|
79
80
|
"@vitest/coverage-v8": "^4.1.8",
|
|
80
|
-
"typescript": "^
|
|
81
|
+
"typescript": "^7.0.2",
|
|
81
82
|
"vitest": "^4.1.8"
|
|
82
83
|
},
|
|
83
84
|
"dependencies": {
|
package/src/constants.mjs
CHANGED
|
@@ -21,8 +21,10 @@ export { DETECTOR_PROFILES, getAllowedExtensions, getEnabledDetectors } from "./
|
|
|
21
21
|
/** @type {string} */
|
|
22
22
|
export const DEFAULT_COMPANY_NAME = "Catalyzed Motivation Inc.";
|
|
23
23
|
|
|
24
|
-
/**
|
|
25
|
-
|
|
24
|
+
/** Header must sit near the top of the file, but a metadata block can legitimately
|
|
25
|
+
* run long; cap the scan generously so a long block's closing `*/` is still seen.
|
|
26
|
+
* @type {number} */
|
|
27
|
+
export const DEFAULT_MAX_HEADER_SCAN_LINES = 200;
|
|
26
28
|
|
|
27
29
|
/**
|
|
28
30
|
* Folders skipped at ANY depth — vendored / VCS directories that are never source and can
|
package/src/detectors/index.mjs
CHANGED
|
@@ -140,7 +140,7 @@ export function getDetectorById(id) {
|
|
|
140
140
|
/**
|
|
141
141
|
* Resolves comment syntax for a file path using detector-specific templates.
|
|
142
142
|
* @param {string} filePath - File path.
|
|
143
|
-
* @param {{ language?: string, enabledDetectors?: string[], disabledDetectors?: string[], detectors?:
|
|
143
|
+
* @param {{ language?: string, enabledDetectors?: string[], disabledDetectors?: string[], detectors?: DetectorProfile[], detectorSyntaxOverrides?: Record<string, { linePrefix?: string, lineSeparator?: string, blockStart?: string, blockLinePrefix?: string, blockEnd?: string }> }} [options={}] - Runtime options. `detectors` overrides the enabled-detector set (matching {@link detectProjectFromMarkers}).
|
|
144
144
|
* @returns {{kind: "block" | "line" | "html", linePrefix?: string, lineSeparator?: string, blockStart?: string, blockLinePrefix?: string, blockEnd?: string}} Syntax descriptor.
|
|
145
145
|
*/
|
|
146
146
|
export function getCommentSyntaxForFile(filePath, options = {}) {
|