@ariestools/toolchain 8.7.15 → 8.7.17
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/dist/actions/api-exposure/analyzer/analyzePackage.d.ts.map +1 -1
- package/dist/actions/api-exposure/analyzer/placement.d.ts +24 -0
- package/dist/actions/api-exposure/analyzer/placement.d.ts.map +1 -0
- package/dist/actions/api-exposure/reporters.d.ts.map +1 -1
- package/dist/actions/api-exposure/types.d.ts +9 -0
- package/dist/actions/api-exposure/types.d.ts.map +1 -1
- package/dist/actions/clean.d.ts.map +1 -1
- package/dist/actions/cleanRuleCatalog.d.ts +11 -0
- package/dist/actions/cleanRuleCatalog.d.ts.map +1 -0
- package/dist/actions/package/clean-outputs.d.ts +19 -1
- package/dist/actions/package/clean-outputs.d.ts.map +1 -1
- package/dist/actions/package/clean-typescript.d.ts +1 -0
- package/dist/actions/package/clean-typescript.d.ts.map +1 -1
- package/dist/actions/package/clean.d.ts +1 -1
- package/dist/actions/package/clean.d.ts.map +1 -1
- package/dist/actions/package/cleanGitignore.d.ts +25 -0
- package/dist/actions/package/cleanGitignore.d.ts.map +1 -0
- package/dist/actions/package/cleanPatterns.d.ts +18 -0
- package/dist/actions/package/cleanPatterns.d.ts.map +1 -0
- package/dist/actions/package/cleanPlan.d.ts +48 -0
- package/dist/actions/package/cleanPlan.d.ts.map +1 -0
- package/dist/actions/package/cleanRules.d.ts +44 -0
- package/dist/actions/package/cleanRules.d.ts.map +1 -0
- package/dist/actions/package/compile/CleanConfig.d.ts +61 -0
- package/dist/actions/package/compile/CleanConfig.d.ts.map +1 -0
- package/dist/actions/package/compile/XyConfig.d.ts +11 -37
- package/dist/actions/package/compile/XyConfig.d.ts.map +1 -1
- package/dist/actions/package/compile/index.d.ts +1 -0
- package/dist/actions/package/compile/index.d.ts.map +1 -1
- package/dist/actions/package/index.d.ts +4 -0
- package/dist/actions/package/index.d.ts.map +1 -1
- package/dist/actions/ruleCatalog.d.ts +3 -22
- package/dist/actions/ruleCatalog.d.ts.map +1 -1
- package/dist/actions/ruleCatalogRender.d.ts +25 -0
- package/dist/actions/ruleCatalogRender.d.ts.map +1 -0
- package/dist/bin/package/build.mjs +11 -5
- package/dist/bin/package/build.mjs.map +1 -1
- package/dist/bin/package/clean.mjs +7565 -47
- package/dist/bin/package/clean.mjs.map +1 -1
- package/dist/bin/package/compile.mjs +3 -3
- package/dist/bin/package/compile.mjs.map +1 -1
- package/dist/bin/package/copy-assets-cjs.mjs.map +1 -1
- package/dist/bin/package/copy-assets-esm.mjs.map +1 -1
- package/dist/bin/package/fix.mjs.map +1 -1
- package/dist/bin/package/lint-verbose.mjs.map +1 -1
- package/dist/bin/package/lint.mjs.map +1 -1
- package/dist/bin/package/publint.mjs +8 -2
- package/dist/bin/package/publint.mjs.map +1 -1
- package/dist/bin/package/recompile.mjs +615 -18
- package/dist/bin/package/recompile.mjs.map +1 -1
- package/dist/bin/package/relint.mjs.map +1 -1
- package/dist/bin/package/sync-layout.mjs.map +1 -1
- package/dist/bin/run-or-exec.mjs.map +1 -1
- package/dist/bin/skills.mjs +275 -298
- package/dist/bin/skills.mjs.map +1 -1
- package/dist/bin/source-map-explorer.mjs.map +1 -1
- package/dist/bin/xy.mjs +652 -196
- package/dist/bin/xy.mjs.map +1 -1
- package/dist/lib/ruleCommandRegistry.d.ts +6 -0
- package/dist/lib/ruleCommandRegistry.d.ts.map +1 -1
- package/package.json +7 -8
- package/dist/actions/claude-check.d.ts +0 -2
- package/dist/actions/claude-check.d.ts.map +0 -1
- package/dist/actions/claude-clean.d.ts +0 -2
- package/dist/actions/claude-clean.d.ts.map +0 -1
- package/dist/actions/claude-commands.d.ts +0 -2
- package/dist/actions/claude-commands.d.ts.map +0 -1
- package/dist/actions/claude-rules.d.ts +0 -4
- package/dist/actions/claude-rules.d.ts.map +0 -1
- package/dist/actions/claude-settings.d.ts +0 -5
- package/dist/actions/claude-settings.d.ts.map +0 -1
- package/dist/actions/claude-skills.d.ts +0 -2
- package/dist/actions/claude-skills.d.ts.map +0 -1
- package/dist/actions/deplint/getInternalSurfaceVouchedPeers.d.ts +0 -13
- package/dist/actions/deplint/getInternalSurfaceVouchedPeers.d.ts.map +0 -1
- package/dist/actions/package/compile/copyTypeFiles.d.ts +0 -2
- package/dist/actions/package/compile/copyTypeFiles.d.ts.map +0 -1
- package/dist/actions/skills/remove.d.ts +0 -9
- package/dist/actions/skills/remove.d.ts.map +0 -1
- package/dist/lib/claudeMdTemplate.d.ts +0 -12
- package/dist/lib/claudeMdTemplate.d.ts.map +0 -1
- package/dist/lib/parsedPackageJSON.d.ts +0 -2
- package/dist/lib/parsedPackageJSON.d.ts.map +0 -1
- package/dist/lib/runInstall.d.ts +0 -2
- package/dist/lib/runInstall.d.ts.map +0 -1
- package/dist/lib/yarn/yarnInitCwd.d.ts +0 -2
- package/dist/lib/yarn/yarnInitCwd.d.ts.map +0 -1
- package/dist/node/actions/analyze.d.ts +0 -2
- package/dist/node/actions/analyze.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/analyzer/analyzePackage.d.ts +0 -28
- package/dist/node/actions/api-exposure/analyzer/analyzePackage.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/analyzer/couplingWalk.d.ts +0 -11
- package/dist/node/actions/api-exposure/analyzer/couplingWalk.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/analyzer/depSignals.d.ts +0 -19
- package/dist/node/actions/api-exposure/analyzer/depSignals.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/analyzer/entryPoints.d.ts +0 -7
- package/dist/node/actions/api-exposure/analyzer/entryPoints.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/analyzer/exposureWalk.d.ts +0 -21
- package/dist/node/actions/api-exposure/analyzer/exposureWalk.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/analyzer/program.d.ts +0 -21
- package/dist/node/actions/api-exposure/analyzer/program.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/apiExposure.d.ts +0 -17
- package/dist/node/actions/api-exposure/apiExposure.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/config.d.ts +0 -21
- package/dist/node/actions/api-exposure/config.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/index.d.ts +0 -9
- package/dist/node/actions/api-exposure/index.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/reporters.d.ts +0 -16
- package/dist/node/actions/api-exposure/reporters.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/rules.d.ts +0 -10
- package/dist/node/actions/api-exposure/rules.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/scoring.d.ts +0 -28
- package/dist/node/actions/api-exposure/scoring.d.ts.map +0 -1
- package/dist/node/actions/api-exposure/types.d.ts +0 -86
- package/dist/node/actions/api-exposure/types.d.ts.map +0 -1
- package/dist/node/actions/barrel/analyzeBarrel.d.ts +0 -22
- package/dist/node/actions/barrel/analyzeBarrel.d.ts.map +0 -1
- package/dist/node/actions/barrel/checkBarrelImportRestrictions.d.ts +0 -12
- package/dist/node/actions/barrel/checkBarrelImportRestrictions.d.ts.map +0 -1
- package/dist/node/actions/barrel/getReExportSpecs.d.ts +0 -11
- package/dist/node/actions/barrel/getReExportSpecs.d.ts.map +0 -1
- package/dist/node/actions/barrel/index.d.ts +0 -6
- package/dist/node/actions/barrel/index.d.ts.map +0 -1
- package/dist/node/actions/barrel/resolveBarrel.d.ts +0 -9
- package/dist/node/actions/barrel/resolveBarrel.d.ts.map +0 -1
- package/dist/node/actions/barrel/restrictionHelpers.d.ts +0 -30
- package/dist/node/actions/barrel/restrictionHelpers.d.ts.map +0 -1
- package/dist/node/actions/build.d.ts +0 -9
- package/dist/node/actions/build.d.ts.map +0 -1
- package/dist/node/actions/clean-eslint.d.ts +0 -3
- package/dist/node/actions/clean-eslint.d.ts.map +0 -1
- package/dist/node/actions/clean.d.ts +0 -14
- package/dist/node/actions/clean.d.ts.map +0 -1
- package/dist/node/actions/compile.d.ts +0 -45
- package/dist/node/actions/compile.d.ts.map +0 -1
- package/dist/node/actions/copy-assets.d.ts +0 -6
- package/dist/node/actions/copy-assets.d.ts.map +0 -1
- package/dist/node/actions/dead/analyzePackage.d.ts +0 -43
- package/dist/node/actions/dead/analyzePackage.d.ts.map +0 -1
- package/dist/node/actions/dead/classifyPackageVisibility.d.ts +0 -4
- package/dist/node/actions/dead/classifyPackageVisibility.d.ts.map +0 -1
- package/dist/node/actions/dead/collectExternalUsage.d.ts +0 -38
- package/dist/node/actions/dead/collectExternalUsage.d.ts.map +0 -1
- package/dist/node/actions/dead/collectSymbols.d.ts +0 -40
- package/dist/node/actions/dead/collectSymbols.d.ts.map +0 -1
- package/dist/node/actions/dead/dead.d.ts +0 -4
- package/dist/node/actions/dead/dead.d.ts.map +0 -1
- package/dist/node/actions/dead/deprecation.d.ts +0 -3
- package/dist/node/actions/dead/deprecation.d.ts.map +0 -1
- package/dist/node/actions/dead/detectActiveCodeWorkspace.d.ts +0 -7
- package/dist/node/actions/dead/detectActiveCodeWorkspace.d.ts.map +0 -1
- package/dist/node/actions/dead/evaluateRules.d.ts +0 -8
- package/dist/node/actions/dead/evaluateRules.d.ts.map +0 -1
- package/dist/node/actions/dead/findWorkspaceFile.d.ts +0 -13
- package/dist/node/actions/dead/findWorkspaceFile.d.ts.map +0 -1
- package/dist/node/actions/dead/fixDeadCode.d.ts +0 -12
- package/dist/node/actions/dead/fixDeadCode.d.ts.map +0 -1
- package/dist/node/actions/dead/index.d.ts +0 -10
- package/dist/node/actions/dead/index.d.ts.map +0 -1
- package/dist/node/actions/dead/parseCodeWorkspace.d.ts +0 -7
- package/dist/node/actions/dead/parseCodeWorkspace.d.ts.map +0 -1
- package/dist/node/actions/dead/propagateExternalUsage.d.ts +0 -4
- package/dist/node/actions/dead/propagateExternalUsage.d.ts.map +0 -1
- package/dist/node/actions/dead/pruneDeadFiles.d.ts +0 -7
- package/dist/node/actions/dead/pruneDeadFiles.d.ts.map +0 -1
- package/dist/node/actions/dead/reporters.d.ts +0 -6
- package/dist/node/actions/dead/reporters.d.ts.map +0 -1
- package/dist/node/actions/dead/ruleConfig.d.ts +0 -5
- package/dist/node/actions/dead/ruleConfig.d.ts.map +0 -1
- package/dist/node/actions/dead/ruleNames.d.ts +0 -4
- package/dist/node/actions/dead/ruleNames.d.ts.map +0 -1
- package/dist/node/actions/dead/rules.d.ts +0 -7
- package/dist/node/actions/dead/rules.d.ts.map +0 -1
- package/dist/node/actions/dead/runDeadAnalysis.d.ts +0 -25
- package/dist/node/actions/dead/runDeadAnalysis.d.ts.map +0 -1
- package/dist/node/actions/dead/runtimeEntries.d.ts +0 -23
- package/dist/node/actions/dead/runtimeEntries.d.ts.map +0 -1
- package/dist/node/actions/dead/sourceEdits.d.ts +0 -7
- package/dist/node/actions/dead/sourceEdits.d.ts.map +0 -1
- package/dist/node/actions/dead/storybookConventions.d.ts +0 -6
- package/dist/node/actions/dead/storybookConventions.d.ts.map +0 -1
- package/dist/node/actions/dead/types.d.ts +0 -68
- package/dist/node/actions/dead/types.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/checkPackage.d.ts +0 -17
- package/dist/node/actions/deplint/checkPackage/checkPackage.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/checkPackageTypes.d.ts +0 -19
- package/dist/node/actions/deplint/checkPackage/checkPackageTypes.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getMismatchedPeerDevVersions.d.ts +0 -11
- package/dist/node/actions/deplint/checkPackage/getMismatchedPeerDevVersions.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnlistedDependencies.d.ts +0 -21
- package/dist/node/actions/deplint/checkPackage/getUnlistedDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnlistedDevDependencies.d.ts +0 -6
- package/dist/node/actions/deplint/checkPackage/getUnlistedDevDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnnecessaryPeerDependencies.d.ts +0 -24
- package/dist/node/actions/deplint/checkPackage/getUnnecessaryPeerDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnsatisfiedPeerDependencies.d.ts +0 -74
- package/dist/node/actions/deplint/checkPackage/getUnsatisfiedPeerDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnusedDependencies.d.ts +0 -12
- package/dist/node/actions/deplint/checkPackage/getUnusedDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnusedDevDependencies.d.ts +0 -7
- package/dist/node/actions/deplint/checkPackage/getUnusedDevDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getUnusedPeerDependencies.d.ts +0 -6
- package/dist/node/actions/deplint/checkPackage/getUnusedPeerDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/getWorkspaceVersionProblems.d.ts +0 -21
- package/dist/node/actions/deplint/checkPackage/getWorkspaceVersionProblems.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/index.d.ts +0 -13
- package/dist/node/actions/deplint/checkPackage/index.d.ts.map +0 -1
- package/dist/node/actions/deplint/checkPackage/legacyPeerCheck.d.ts +0 -13
- package/dist/node/actions/deplint/checkPackage/legacyPeerCheck.d.ts.map +0 -1
- package/dist/node/actions/deplint/deplint.d.ts +0 -20
- package/dist/node/actions/deplint/deplint.d.ts.map +0 -1
- package/dist/node/actions/deplint/engine.d.ts +0 -15
- package/dist/node/actions/deplint/engine.d.ts.map +0 -1
- package/dist/node/actions/deplint/fetchPackageManifest.d.ts +0 -25
- package/dist/node/actions/deplint/fetchPackageManifest.d.ts.map +0 -1
- package/dist/node/actions/deplint/findFiles.d.ts +0 -6
- package/dist/node/actions/deplint/findFiles.d.ts.map +0 -1
- package/dist/node/actions/deplint/findFilesByGlob.d.ts +0 -2
- package/dist/node/actions/deplint/findFilesByGlob.d.ts.map +0 -1
- package/dist/node/actions/deplint/fixer.d.ts +0 -3
- package/dist/node/actions/deplint/fixer.d.ts.map +0 -1
- package/dist/node/actions/deplint/getBasePackageName.d.ts +0 -2
- package/dist/node/actions/deplint/getBasePackageName.d.ts.map +0 -1
- package/dist/node/actions/deplint/getCliReferencedPackagesFromFiles.d.ts +0 -12
- package/dist/node/actions/deplint/getCliReferencedPackagesFromFiles.d.ts.map +0 -1
- package/dist/node/actions/deplint/getDependenciesFromPackageJson.d.ts +0 -9
- package/dist/node/actions/deplint/getDependenciesFromPackageJson.d.ts.map +0 -1
- package/dist/node/actions/deplint/getExtendsFromTsconfigs.d.ts +0 -10
- package/dist/node/actions/deplint/getExtendsFromTsconfigs.d.ts.map +0 -1
- package/dist/node/actions/deplint/getExternalImportsFromFiles.d.ts +0 -12
- package/dist/node/actions/deplint/getExternalImportsFromFiles.d.ts.map +0 -1
- package/dist/node/actions/deplint/getImportsFromFile.d.ts +0 -4
- package/dist/node/actions/deplint/getImportsFromFile.d.ts.map +0 -1
- package/dist/node/actions/deplint/getRequiredPeerDependencies.d.ts +0 -10
- package/dist/node/actions/deplint/getRequiredPeerDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/getScriptReferencedPackages.d.ts +0 -8
- package/dist/node/actions/deplint/getScriptReferencedPackages.d.ts.map +0 -1
- package/dist/node/actions/deplint/getStorybookConfigImports.d.ts +0 -3
- package/dist/node/actions/deplint/getStorybookConfigImports.d.ts.map +0 -1
- package/dist/node/actions/deplint/implicitDevDependencies.d.ts +0 -15
- package/dist/node/actions/deplint/implicitDevDependencies.d.ts.map +0 -1
- package/dist/node/actions/deplint/index.d.ts +0 -11
- package/dist/node/actions/deplint/index.d.ts.map +0 -1
- package/dist/node/actions/deplint/isTerminalPackage.d.ts +0 -25
- package/dist/node/actions/deplint/isTerminalPackage.d.ts.map +0 -1
- package/dist/node/actions/deplint/loader.d.ts +0 -4
- package/dist/node/actions/deplint/loader.d.ts.map +0 -1
- package/dist/node/actions/deplint/packageEditor.d.ts +0 -11
- package/dist/node/actions/deplint/packageEditor.d.ts.map +0 -1
- package/dist/node/actions/deplint/packageJsonEditor.d.ts +0 -97
- package/dist/node/actions/deplint/packageJsonEditor.d.ts.map +0 -1
- package/dist/node/actions/deplint/peerRangeOptions.d.ts +0 -10
- package/dist/node/actions/deplint/peerRangeOptions.d.ts.map +0 -1
- package/dist/node/actions/deplint/reporters.d.ts +0 -8
- package/dist/node/actions/deplint/reporters.d.ts.map +0 -1
- package/dist/node/actions/deplint/resolvePeerBumpFixes.d.ts +0 -24
- package/dist/node/actions/deplint/resolvePeerBumpFixes.d.ts.map +0 -1
- package/dist/node/actions/deplint/ruleConfig.d.ts +0 -5
- package/dist/node/actions/deplint/ruleConfig.d.ts.map +0 -1
- package/dist/node/actions/deplint/rules.d.ts +0 -4
- package/dist/node/actions/deplint/rules.d.ts.map +0 -1
- package/dist/node/actions/deplint/rulesDiagnostic.d.ts +0 -4
- package/dist/node/actions/deplint/rulesDiagnostic.d.ts.map +0 -1
- package/dist/node/actions/deplint/rulesMisplaced.d.ts +0 -4
- package/dist/node/actions/deplint/rulesMisplaced.d.ts.map +0 -1
- package/dist/node/actions/deplint/snapshot.d.ts +0 -22
- package/dist/node/actions/deplint/snapshot.d.ts.map +0 -1
- package/dist/node/actions/deplint/tsScriptsAliases.d.ts +0 -11
- package/dist/node/actions/deplint/tsScriptsAliases.d.ts.map +0 -1
- package/dist/node/actions/deplint/types.d.ts +0 -295
- package/dist/node/actions/deplint/types.d.ts.map +0 -1
- package/dist/node/actions/deplint/versionMismatchFixes.d.ts +0 -4
- package/dist/node/actions/deplint/versionMismatchFixes.d.ts.map +0 -1
- package/dist/node/actions/deploy.d.ts +0 -3
- package/dist/node/actions/deploy.d.ts.map +0 -1
- package/dist/node/actions/eject.d.ts +0 -2
- package/dist/node/actions/eject.d.ts.map +0 -1
- package/dist/node/actions/fix.d.ts +0 -7
- package/dist/node/actions/fix.d.ts.map +0 -1
- package/dist/node/actions/gitignore.d.ts +0 -4
- package/dist/node/actions/gitignore.d.ts.map +0 -1
- package/dist/node/actions/gitlint-fix.d.ts +0 -2
- package/dist/node/actions/gitlint-fix.d.ts.map +0 -1
- package/dist/node/actions/gitlint.d.ts +0 -2
- package/dist/node/actions/gitlint.d.ts.map +0 -1
- package/dist/node/actions/incremental.d.ts +0 -46
- package/dist/node/actions/incremental.d.ts.map +0 -1
- package/dist/node/actions/index.d.ts +0 -54
- package/dist/node/actions/index.d.ts.map +0 -1
- package/dist/node/actions/install.d.ts +0 -2
- package/dist/node/actions/install.d.ts.map +0 -1
- package/dist/node/actions/license.d.ts +0 -2
- package/dist/node/actions/license.d.ts.map +0 -1
- package/dist/node/actions/lint-config.d.ts +0 -16
- package/dist/node/actions/lint-config.d.ts.map +0 -1
- package/dist/node/actions/lint-init.d.ts +0 -16
- package/dist/node/actions/lint-init.d.ts.map +0 -1
- package/dist/node/actions/lint.d.ts +0 -36
- package/dist/node/actions/lint.d.ts.map +0 -1
- package/dist/node/actions/lintNext.d.ts +0 -14
- package/dist/node/actions/lintNext.d.ts.map +0 -1
- package/dist/node/actions/lintNextWorker.d.ts +0 -21
- package/dist/node/actions/lintNextWorker.d.ts.map +0 -1
- package/dist/node/actions/lintTierAnalysis.d.ts +0 -59
- package/dist/node/actions/lintTierAnalysis.d.ts.map +0 -1
- package/dist/node/actions/lintlint.d.ts +0 -13
- package/dist/node/actions/lintlint.d.ts.map +0 -1
- package/dist/node/actions/node-lint.d.ts +0 -19
- package/dist/node/actions/node-lint.d.ts.map +0 -1
- package/dist/node/actions/npmignore-gen.d.ts +0 -2
- package/dist/node/actions/npmignore-gen.d.ts.map +0 -1
- package/dist/node/actions/orphan.d.ts +0 -6
- package/dist/node/actions/orphan.d.ts.map +0 -1
- package/dist/node/actions/package/clean-outputs.d.ts +0 -6
- package/dist/node/actions/package/clean-outputs.d.ts.map +0 -1
- package/dist/node/actions/package/clean-typescript.d.ts +0 -3
- package/dist/node/actions/package/clean-typescript.d.ts.map +0 -1
- package/dist/node/actions/package/clean.d.ts +0 -3
- package/dist/node/actions/package/clean.d.ts.map +0 -1
- package/dist/node/actions/package/compile/ApiExposureConfig.d.ts +0 -58
- package/dist/node/actions/package/compile/ApiExposureConfig.d.ts.map +0 -1
- package/dist/node/actions/package/compile/MonolithConfig.d.ts +0 -85
- package/dist/node/actions/package/compile/MonolithConfig.d.ts.map +0 -1
- package/dist/node/actions/package/compile/XyConfig.d.ts +0 -462
- package/dist/node/actions/package/compile/XyConfig.d.ts.map +0 -1
- package/dist/node/actions/package/compile/buildEntries.d.ts +0 -3
- package/dist/node/actions/package/compile/buildEntries.d.ts.map +0 -1
- package/dist/node/actions/package/compile/compile.d.ts +0 -7
- package/dist/node/actions/package/compile/compile.d.ts.map +0 -1
- package/dist/node/actions/package/compile/createProgramFromConfig.d.ts +0 -25
- package/dist/node/actions/package/compile/createProgramFromConfig.d.ts.map +0 -1
- package/dist/node/actions/package/compile/createTypescriptConfig.d.ts +0 -29
- package/dist/node/actions/package/compile/createTypescriptConfig.d.ts.map +0 -1
- package/dist/node/actions/package/compile/deepMerge.d.ts +0 -4
- package/dist/node/actions/package/compile/deepMerge.d.ts.map +0 -1
- package/dist/node/actions/package/compile/entryOutputName.d.ts +0 -5
- package/dist/node/actions/package/compile/entryOutputName.d.ts.map +0 -1
- package/dist/node/actions/package/compile/findWorkspaceRoot.d.ts +0 -5
- package/dist/node/actions/package/compile/findWorkspaceRoot.d.ts.map +0 -1
- package/dist/node/actions/package/compile/getCompilerOptions.d.ts +0 -3
- package/dist/node/actions/package/compile/getCompilerOptions.d.ts.map +0 -1
- package/dist/node/actions/package/compile/index.d.ts +0 -16
- package/dist/node/actions/package/compile/index.d.ts.map +0 -1
- package/dist/node/actions/package/compile/inputs.d.ts +0 -2
- package/dist/node/actions/package/compile/inputs.d.ts.map +0 -1
- package/dist/node/actions/package/compile/monolithCompileDeclarations.d.ts +0 -14
- package/dist/node/actions/package/compile/monolithCompileDeclarations.d.ts.map +0 -1
- package/dist/node/actions/package/compile/monolithCompileEntries.d.ts +0 -20
- package/dist/node/actions/package/compile/monolithCompileEntries.d.ts.map +0 -1
- package/dist/node/actions/package/compile/monolithCompileLayout.d.ts +0 -42
- package/dist/node/actions/package/compile/monolithCompileLayout.d.ts.map +0 -1
- package/dist/node/actions/package/compile/packageCompileEsbuild.d.ts +0 -18
- package/dist/node/actions/package/compile/packageCompileEsbuild.d.ts.map +0 -1
- package/dist/node/actions/package/compile/packageCompileMonolith.d.ts +0 -10
- package/dist/node/actions/package/compile/packageCompileMonolith.d.ts.map +0 -1
- package/dist/node/actions/package/compile/packageCompileTsc.d.ts +0 -3
- package/dist/node/actions/package/compile/packageCompileTsc.d.ts.map +0 -1
- package/dist/node/actions/package/compile/packageCompileTsup.d.ts +0 -6
- package/dist/node/actions/package/compile/packageCompileTsup.d.ts.map +0 -1
- package/dist/node/actions/package/compile/packageCompileVendor.d.ts +0 -4
- package/dist/node/actions/package/compile/packageCompileVendor.d.ts.map +0 -1
- package/dist/node/actions/package/compile/resolveCompileBundleOptions.d.ts +0 -13
- package/dist/node/actions/package/compile/resolveCompileBundleOptions.d.ts.map +0 -1
- package/dist/node/actions/package/compile/resolveCompilePlatforms.d.ts +0 -23
- package/dist/node/actions/package/compile/resolveCompilePlatforms.d.ts.map +0 -1
- package/dist/node/actions/package/compile/resolvePlatformTypes.d.ts +0 -5
- package/dist/node/actions/package/compile/resolvePlatformTypes.d.ts.map +0 -1
- package/dist/node/actions/package/compile/runTsc.d.ts +0 -2
- package/dist/node/actions/package/compile/runTsc.d.ts.map +0 -1
- package/dist/node/actions/package/compile/validateFullPackage.d.ts +0 -2
- package/dist/node/actions/package/compile/validateFullPackage.d.ts.map +0 -1
- package/dist/node/actions/package/compile/vendorCompile.d.ts +0 -6
- package/dist/node/actions/package/compile/vendorCompile.d.ts.map +0 -1
- package/dist/node/actions/package/compile/vendorCompileEmit.d.ts +0 -8
- package/dist/node/actions/package/compile/vendorCompileEmit.d.ts.map +0 -1
- package/dist/node/actions/package/compile/vendorCompileInternals.d.ts +0 -31
- package/dist/node/actions/package/compile/vendorCompileInternals.d.ts.map +0 -1
- package/dist/node/actions/package/compile/vendorCompileRewrite.d.ts +0 -3
- package/dist/node/actions/package/compile/vendorCompileRewrite.d.ts.map +0 -1
- package/dist/node/actions/package/compile/vendorCompileTypes.d.ts +0 -31
- package/dist/node/actions/package/compile/vendorCompileTypes.d.ts.map +0 -1
- package/dist/node/actions/package/compileTargetsPublint.d.ts +0 -13
- package/dist/node/actions/package/compileTargetsPublint.d.ts.map +0 -1
- package/dist/node/actions/package/copy-assets.d.ts +0 -5
- package/dist/node/actions/package/copy-assets.d.ts.map +0 -1
- package/dist/node/actions/package/expectedCompileOutputs.d.ts +0 -11
- package/dist/node/actions/package/expectedCompileOutputs.d.ts.map +0 -1
- package/dist/node/actions/package/exportConditionPublint.d.ts +0 -9
- package/dist/node/actions/package/exportConditionPublint.d.ts.map +0 -1
- package/dist/node/actions/package/exportMapPublint.d.ts +0 -7
- package/dist/node/actions/package/exportMapPublint.d.ts.map +0 -1
- package/dist/node/actions/package/index.d.ts +0 -9
- package/dist/node/actions/package/index.d.ts.map +0 -1
- package/dist/node/actions/package/lint.d.ts +0 -2
- package/dist/node/actions/package/lint.d.ts.map +0 -1
- package/dist/node/actions/package/platformPublint.d.ts +0 -7
- package/dist/node/actions/package/platformPublint.d.ts.map +0 -1
- package/dist/node/actions/package/publint.d.ts +0 -16
- package/dist/node/actions/package/publint.d.ts.map +0 -1
- package/dist/node/actions/package/recompile.d.ts +0 -3
- package/dist/node/actions/package/recompile.d.ts.map +0 -1
- package/dist/node/actions/package-lint-deps.d.ts +0 -47
- package/dist/node/actions/package-lint-deps.d.ts.map +0 -1
- package/dist/node/actions/package-lint-engines.d.ts +0 -22
- package/dist/node/actions/package-lint-engines.d.ts.map +0 -1
- package/dist/node/actions/package-lint-pnpm.d.ts +0 -11
- package/dist/node/actions/package-lint-pnpm.d.ts.map +0 -1
- package/dist/node/actions/package-lint-specs.d.ts +0 -9
- package/dist/node/actions/package-lint-specs.d.ts.map +0 -1
- package/dist/node/actions/package-lint.d.ts +0 -7
- package/dist/node/actions/package-lint.d.ts.map +0 -1
- package/dist/node/actions/packman/clean.d.ts +0 -5
- package/dist/node/actions/packman/clean.d.ts.map +0 -1
- package/dist/node/actions/packman/convert.d.ts +0 -10
- package/dist/node/actions/packman/convert.d.ts.map +0 -1
- package/dist/node/actions/packman/convertToBun.d.ts +0 -2
- package/dist/node/actions/packman/convertToBun.d.ts.map +0 -1
- package/dist/node/actions/packman/convertToNpm.d.ts +0 -2
- package/dist/node/actions/packman/convertToNpm.d.ts.map +0 -1
- package/dist/node/actions/packman/convertToPnpm.d.ts +0 -2
- package/dist/node/actions/packman/convertToPnpm.d.ts.map +0 -1
- package/dist/node/actions/packman/convertToYarn.d.ts +0 -2
- package/dist/node/actions/packman/convertToYarn.d.ts.map +0 -1
- package/dist/node/actions/packman/index.d.ts +0 -5
- package/dist/node/actions/packman/index.d.ts.map +0 -1
- package/dist/node/actions/packman/lint.d.ts +0 -6
- package/dist/node/actions/packman/lint.d.ts.map +0 -1
- package/dist/node/actions/packman/rewriteScripts.d.ts +0 -5
- package/dist/node/actions/packman/rewriteScripts.d.ts.map +0 -1
- package/dist/node/actions/packman/rewriteSourceImports.d.ts +0 -2
- package/dist/node/actions/packman/rewriteSourceImports.d.ts.map +0 -1
- package/dist/node/actions/packman/swapTsScriptsDependency.d.ts +0 -2
- package/dist/node/actions/packman/swapTsScriptsDependency.d.ts.map +0 -1
- package/dist/node/actions/publint.d.ts +0 -48
- package/dist/node/actions/publint.d.ts.map +0 -1
- package/dist/node/actions/publish.d.ts +0 -22
- package/dist/node/actions/publish.d.ts.map +0 -1
- package/dist/node/actions/reactTest.d.ts +0 -2
- package/dist/node/actions/reactTest.d.ts.map +0 -1
- package/dist/node/actions/rebuild.d.ts +0 -7
- package/dist/node/actions/rebuild.d.ts.map +0 -1
- package/dist/node/actions/recompile.d.ts +0 -16
- package/dist/node/actions/recompile.d.ts.map +0 -1
- package/dist/node/actions/reinstall.d.ts +0 -2
- package/dist/node/actions/reinstall.d.ts.map +0 -1
- package/dist/node/actions/releaseAgeExcludeScopes.d.ts +0 -13
- package/dist/node/actions/releaseAgeExcludeScopes.d.ts.map +0 -1
- package/dist/node/actions/relint.d.ts +0 -24
- package/dist/node/actions/relint.d.ts.map +0 -1
- package/dist/node/actions/repo-init.d.ts +0 -14
- package/dist/node/actions/repo-init.d.ts.map +0 -1
- package/dist/node/actions/republint.d.ts +0 -13
- package/dist/node/actions/republint.d.ts.map +0 -1
- package/dist/node/actions/result.d.ts +0 -44
- package/dist/node/actions/result.d.ts.map +0 -1
- package/dist/node/actions/retest.d.ts +0 -5
- package/dist/node/actions/retest.d.ts.map +0 -1
- package/dist/node/actions/secure.d.ts +0 -7
- package/dist/node/actions/secure.d.ts.map +0 -1
- package/dist/node/actions/sitemap.d.ts +0 -2
- package/dist/node/actions/sitemap.d.ts.map +0 -1
- package/dist/node/actions/skills/defaults.d.ts +0 -6
- package/dist/node/actions/skills/defaults.d.ts.map +0 -1
- package/dist/node/actions/skills/detectProfile.d.ts +0 -10
- package/dist/node/actions/skills/detectProfile.d.ts.map +0 -1
- package/dist/node/actions/skills/index.d.ts +0 -9
- package/dist/node/actions/skills/index.d.ts.map +0 -1
- package/dist/node/actions/skills/installed.d.ts +0 -10
- package/dist/node/actions/skills/installed.d.ts.map +0 -1
- package/dist/node/actions/skills/lint.d.ts +0 -26
- package/dist/node/actions/skills/lint.d.ts.map +0 -1
- package/dist/node/actions/skills/passthrough.d.ts +0 -25
- package/dist/node/actions/skills/passthrough.d.ts.map +0 -1
- package/dist/node/actions/skills/skillRules.d.ts +0 -9
- package/dist/node/actions/skills/skillRules.d.ts.map +0 -1
- package/dist/node/actions/skills/updo.d.ts +0 -4
- package/dist/node/actions/skills/updo.d.ts.map +0 -1
- package/dist/node/actions/skills/versions.d.ts +0 -10
- package/dist/node/actions/skills/versions.d.ts.map +0 -1
- package/dist/node/actions/sonar.d.ts +0 -2
- package/dist/node/actions/sonar.d.ts.map +0 -1
- package/dist/node/actions/start.d.ts +0 -2
- package/dist/node/actions/start.d.ts.map +0 -1
- package/dist/node/actions/statics.d.ts +0 -2
- package/dist/node/actions/statics.d.ts.map +0 -1
- package/dist/node/actions/test.d.ts +0 -5
- package/dist/node/actions/test.d.ts.map +0 -1
- package/dist/node/actions/tsc-validate/index.d.ts +0 -3
- package/dist/node/actions/tsc-validate/index.d.ts.map +0 -1
- package/dist/node/actions/tsc-validate/sharedValidate.d.ts +0 -34
- package/dist/node/actions/tsc-validate/sharedValidate.d.ts.map +0 -1
- package/dist/node/actions/tsc-validate/tscValidate.d.ts +0 -35
- package/dist/node/actions/tsc-validate/tscValidate.d.ts.map +0 -1
- package/dist/node/actions/up.d.ts +0 -2
- package/dist/node/actions/up.d.ts.map +0 -1
- package/dist/node/actions/updo.d.ts +0 -9
- package/dist/node/actions/updo.d.ts.map +0 -1
- package/dist/node/actions/work/id.d.ts +0 -8
- package/dist/node/actions/work/id.d.ts.map +0 -1
- package/dist/node/actions/work/index.d.ts +0 -131
- package/dist/node/actions/work/index.d.ts.map +0 -1
- package/dist/node/actions/work/inline.d.ts +0 -8
- package/dist/node/actions/work/inline.d.ts.map +0 -1
- package/dist/node/actions/work/priority.d.ts +0 -5
- package/dist/node/actions/work/priority.d.ts.map +0 -1
- package/dist/node/actions/work/schema.d.ts +0 -81
- package/dist/node/actions/work/schema.d.ts.map +0 -1
- package/dist/node/actions/work/store.d.ts +0 -23
- package/dist/node/actions/work/store.d.ts.map +0 -1
- package/dist/node/bin/package/build.d.ts +0 -3
- package/dist/node/bin/package/build.d.ts.map +0 -1
- package/dist/node/bin/package/clean-outputs.d.ts +0 -3
- package/dist/node/bin/package/clean-outputs.d.ts.map +0 -1
- package/dist/node/bin/package/clean-typescript.d.ts +0 -3
- package/dist/node/bin/package/clean-typescript.d.ts.map +0 -1
- package/dist/node/bin/package/clean.d.ts +0 -3
- package/dist/node/bin/package/clean.d.ts.map +0 -1
- package/dist/node/bin/package/compile-tsup.d.ts +0 -3
- package/dist/node/bin/package/compile-tsup.d.ts.map +0 -1
- package/dist/node/bin/package/compile.d.ts +0 -3
- package/dist/node/bin/package/compile.d.ts.map +0 -1
- package/dist/node/bin/package/copy-assets-cjs.d.ts +0 -3
- package/dist/node/bin/package/copy-assets-cjs.d.ts.map +0 -1
- package/dist/node/bin/package/copy-assets-esm.d.ts +0 -3
- package/dist/node/bin/package/copy-assets-esm.d.ts.map +0 -1
- package/dist/node/bin/package/fix.d.ts +0 -3
- package/dist/node/bin/package/fix.d.ts.map +0 -1
- package/dist/node/bin/package/lint-verbose.d.ts +0 -3
- package/dist/node/bin/package/lint-verbose.d.ts.map +0 -1
- package/dist/node/bin/package/lint.d.ts +0 -3
- package/dist/node/bin/package/lint.d.ts.map +0 -1
- package/dist/node/bin/package/publint.d.ts +0 -3
- package/dist/node/bin/package/publint.d.ts.map +0 -1
- package/dist/node/bin/package/recompile.d.ts +0 -3
- package/dist/node/bin/package/recompile.d.ts.map +0 -1
- package/dist/node/bin/package/relint.d.ts +0 -3
- package/dist/node/bin/package/relint.d.ts.map +0 -1
- package/dist/node/bin/package/sync-layout.d.ts +0 -3
- package/dist/node/bin/package/sync-layout.d.ts.map +0 -1
- package/dist/node/bin/run-or-exec.d.ts +0 -3
- package/dist/node/bin/run-or-exec.d.ts.map +0 -1
- package/dist/node/bin/xy.d.ts +0 -3
- package/dist/node/bin/xy.d.ts.map +0 -1
- package/dist/node/index.d.ts +0 -6
- package/dist/node/index.d.ts.map +0 -1
- package/dist/node/lib/bundledCliPath.d.ts +0 -4
- package/dist/node/lib/bundledCliPath.d.ts.map +0 -1
- package/dist/node/lib/checkResult.d.ts +0 -2
- package/dist/node/lib/checkResult.d.ts.map +0 -1
- package/dist/node/lib/concurrency.d.ts +0 -5
- package/dist/node/lib/concurrency.d.ts.map +0 -1
- package/dist/node/lib/copyAssetFiles.d.ts +0 -10
- package/dist/node/lib/copyAssetFiles.d.ts.map +0 -1
- package/dist/node/lib/createBuildConfig.d.ts +0 -2
- package/dist/node/lib/createBuildConfig.d.ts.map +0 -1
- package/dist/node/lib/crossSpawn.d.ts +0 -6
- package/dist/node/lib/crossSpawn.d.ts.map +0 -1
- package/dist/node/lib/deepMerge.d.ts +0 -24
- package/dist/node/lib/deepMerge.d.ts.map +0 -1
- package/dist/node/lib/defaultBuildConfig.d.ts +0 -9
- package/dist/node/lib/defaultBuildConfig.d.ts.map +0 -1
- package/dist/node/lib/deleteGlob.d.ts +0 -2
- package/dist/node/lib/deleteGlob.d.ts.map +0 -1
- package/dist/node/lib/dependencies/DuplicateDetector.d.ts +0 -7
- package/dist/node/lib/dependencies/DuplicateDetector.d.ts.map +0 -1
- package/dist/node/lib/dependencies/detectDuplicateDependencies.d.ts +0 -2
- package/dist/node/lib/dependencies/detectDuplicateDependencies.d.ts.map +0 -1
- package/dist/node/lib/dependencies/index.d.ts +0 -4
- package/dist/node/lib/dependencies/index.d.ts.map +0 -1
- package/dist/node/lib/dependencies/workspaceCycles.d.ts +0 -15
- package/dist/node/lib/dependencies/workspaceCycles.d.ts.map +0 -1
- package/dist/node/lib/deprecationMigrate.d.ts +0 -2
- package/dist/node/lib/deprecationMigrate.d.ts.map +0 -1
- package/dist/node/lib/eslintCache.d.ts +0 -4
- package/dist/node/lib/eslintCache.d.ts.map +0 -1
- package/dist/node/lib/file/ReadFileSyncOptions.d.ts +0 -6
- package/dist/node/lib/file/ReadFileSyncOptions.d.ts.map +0 -1
- package/dist/node/lib/file/constants.d.ts +0 -3
- package/dist/node/lib/file/constants.d.ts.map +0 -1
- package/dist/node/lib/file/fileLines.d.ts +0 -6
- package/dist/node/lib/file/fileLines.d.ts.map +0 -1
- package/dist/node/lib/file/index.d.ts +0 -5
- package/dist/node/lib/file/index.d.ts.map +0 -1
- package/dist/node/lib/file/tryReadFileSync.d.ts +0 -4
- package/dist/node/lib/file/tryReadFileSync.d.ts.map +0 -1
- package/dist/node/lib/fillTemplate.d.ts +0 -2
- package/dist/node/lib/fillTemplate.d.ts.map +0 -1
- package/dist/node/lib/generateIgnoreFiles.d.ts +0 -2
- package/dist/node/lib/generateIgnoreFiles.d.ts.map +0 -1
- package/dist/node/lib/gitConfig.d.ts +0 -25
- package/dist/node/lib/gitConfig.d.ts.map +0 -1
- package/dist/node/lib/gitignoreTemplate.d.ts +0 -2
- package/dist/node/lib/gitignoreTemplate.d.ts.map +0 -1
- package/dist/node/lib/index.d.ts +0 -45
- package/dist/node/lib/index.d.ts.map +0 -1
- package/dist/node/lib/initCwd.d.ts +0 -2
- package/dist/node/lib/initCwd.d.ts.map +0 -1
- package/dist/node/lib/jsonFormatters.d.ts +0 -2
- package/dist/node/lib/jsonFormatters.d.ts.map +0 -1
- package/dist/node/lib/latestVersions.d.ts +0 -8
- package/dist/node/lib/latestVersions.d.ts.map +0 -1
- package/dist/node/lib/loadConfig.d.ts +0 -10
- package/dist/node/lib/loadConfig.d.ts.map +0 -1
- package/dist/node/lib/match.d.ts +0 -21
- package/dist/node/lib/match.d.ts.map +0 -1
- package/dist/node/lib/npmLatestVersion.d.ts +0 -3
- package/dist/node/lib/npmLatestVersion.d.ts.map +0 -1
- package/dist/node/lib/packageManagerRuntime.d.ts +0 -25
- package/dist/node/lib/packageManagerRuntime.d.ts.map +0 -1
- package/dist/node/lib/packageName.d.ts +0 -2
- package/dist/node/lib/packageName.d.ts.map +0 -1
- package/dist/node/lib/parsedPackageJson.d.ts +0 -2
- package/dist/node/lib/parsedPackageJson.d.ts.map +0 -1
- package/dist/node/lib/pnpmConfig/index.d.ts +0 -2
- package/dist/node/lib/pnpmConfig/index.d.ts.map +0 -1
- package/dist/node/lib/pnpmConfig/readMinReleaseAge.d.ts +0 -18
- package/dist/node/lib/pnpmConfig/readMinReleaseAge.d.ts.map +0 -1
- package/dist/node/lib/processEx.d.ts +0 -2
- package/dist/node/lib/processEx.d.ts.map +0 -1
- package/dist/node/lib/repoTemplates.d.ts +0 -7
- package/dist/node/lib/repoTemplates.d.ts.map +0 -1
- package/dist/node/lib/reporting/index.d.ts +0 -3
- package/dist/node/lib/reporting/index.d.ts.map +0 -1
- package/dist/node/lib/reporting/runWithEnvelope.d.ts +0 -15
- package/dist/node/lib/reporting/runWithEnvelope.d.ts.map +0 -1
- package/dist/node/lib/reporting/xyReporter.d.ts +0 -27
- package/dist/node/lib/reporting/xyReporter.d.ts.map +0 -1
- package/dist/node/lib/runSteps.d.ts +0 -3
- package/dist/node/lib/runSteps.d.ts.map +0 -1
- package/dist/node/lib/runStepsAsync.d.ts +0 -4
- package/dist/node/lib/runStepsAsync.d.ts.map +0 -1
- package/dist/node/lib/runXy.d.ts +0 -2
- package/dist/node/lib/runXy.d.ts.map +0 -1
- package/dist/node/lib/runXyWithWarning.d.ts +0 -2
- package/dist/node/lib/runXyWithWarning.d.ts.map +0 -1
- package/dist/node/lib/safeExit.d.ts +0 -8
- package/dist/node/lib/safeExit.d.ts.map +0 -1
- package/dist/node/lib/secure/classify.d.ts +0 -8
- package/dist/node/lib/secure/classify.d.ts.map +0 -1
- package/dist/node/lib/secure/collectDeclaredDependencies.d.ts +0 -6
- package/dist/node/lib/secure/collectDeclaredDependencies.d.ts.map +0 -1
- package/dist/node/lib/secure/fetchPackageSecurityMetadata.d.ts +0 -8
- package/dist/node/lib/secure/fetchPackageSecurityMetadata.d.ts.map +0 -1
- package/dist/node/lib/secure/index.d.ts +0 -7
- package/dist/node/lib/secure/index.d.ts.map +0 -1
- package/dist/node/lib/secure/interfaces.d.ts +0 -35
- package/dist/node/lib/secure/interfaces.d.ts.map +0 -1
- package/dist/node/lib/secure/renderSecurityAudit.d.ts +0 -4
- package/dist/node/lib/secure/renderSecurityAudit.d.ts.map +0 -1
- package/dist/node/lib/secure/runSecurityAudit.d.ts +0 -15
- package/dist/node/lib/secure/runSecurityAudit.d.ts.map +0 -1
- package/dist/node/lib/shouldRunInstall.d.ts +0 -2
- package/dist/node/lib/shouldRunInstall.d.ts.map +0 -1
- package/dist/node/lib/string/empty.d.ts +0 -3
- package/dist/node/lib/string/empty.d.ts.map +0 -1
- package/dist/node/lib/string/index.d.ts +0 -4
- package/dist/node/lib/string/index.d.ts.map +0 -1
- package/dist/node/lib/string/localeCompare.d.ts +0 -2
- package/dist/node/lib/string/localeCompare.d.ts.map +0 -1
- package/dist/node/lib/string/union.d.ts +0 -2
- package/dist/node/lib/string/union.d.ts.map +0 -1
- package/dist/node/lib/toolchainVersion.d.ts +0 -3
- package/dist/node/lib/toolchainVersion.d.ts.map +0 -1
- package/dist/node/lib/tryRunLocalScript.d.ts +0 -10
- package/dist/node/lib/tryRunLocalScript.d.ts.map +0 -1
- package/dist/node/lib/updo/applyUpdates.d.ts +0 -4
- package/dist/node/lib/updo/applyUpdates.d.ts.map +0 -1
- package/dist/node/lib/updo/collectWorkspaceDeps.d.ts +0 -4
- package/dist/node/lib/updo/collectWorkspaceDeps.d.ts.map +0 -1
- package/dist/node/lib/updo/fetchRegistryInfo.d.ts +0 -37
- package/dist/node/lib/updo/fetchRegistryInfo.d.ts.map +0 -1
- package/dist/node/lib/updo/index.d.ts +0 -9
- package/dist/node/lib/updo/index.d.ts.map +0 -1
- package/dist/node/lib/updo/interactiveSelect.d.ts +0 -31
- package/dist/node/lib/updo/interactiveSelect.d.ts.map +0 -1
- package/dist/node/lib/updo/interfaces.d.ts +0 -50
- package/dist/node/lib/updo/interfaces.d.ts.map +0 -1
- package/dist/node/lib/updo/renderTable.d.ts +0 -3
- package/dist/node/lib/updo/renderTable.d.ts.map +0 -1
- package/dist/node/lib/updo/resolveVersions.d.ts +0 -19
- package/dist/node/lib/updo/resolveVersions.d.ts.map +0 -1
- package/dist/node/lib/updo/runUpdo.d.ts +0 -27
- package/dist/node/lib/updo/runUpdo.d.ts.map +0 -1
- package/dist/node/lib/withErrnoException.d.ts +0 -2
- package/dist/node/lib/withErrnoException.d.ts.map +0 -1
- package/dist/node/lib/withError.d.ts +0 -2
- package/dist/node/lib/withError.d.ts.map +0 -1
- package/dist/node/lib/yarn/index.d.ts +0 -3
- package/dist/node/lib/yarn/index.d.ts.map +0 -1
- package/dist/node/lib/yarn/isYarnVersionOrGreater.d.ts +0 -2
- package/dist/node/lib/yarn/isYarnVersionOrGreater.d.ts.map +0 -1
- package/dist/node/lib/yarn/workspace/Workspace.d.ts +0 -2
- package/dist/node/lib/yarn/workspace/Workspace.d.ts.map +0 -1
- package/dist/node/lib/yarn/workspace/index.d.ts +0 -3
- package/dist/node/lib/yarn/workspace/index.d.ts.map +0 -1
- package/dist/node/lib/yarn/workspace/yarnWorkspace.d.ts +0 -3
- package/dist/node/lib/yarn/workspace/yarnWorkspace.d.ts.map +0 -1
- package/dist/node/lib/yarn/workspace/yarnWorkspaces.d.ts +0 -3
- package/dist/node/lib/yarn/workspace/yarnWorkspaces.d.ts.map +0 -1
- package/dist/node/loadPackageConfig.d.ts +0 -40
- package/dist/node/loadPackageConfig.d.ts.map +0 -1
- package/dist/node/pm/PackageManager.d.ts +0 -85
- package/dist/node/pm/PackageManager.d.ts.map +0 -1
- package/dist/node/pm/bunPackageManager.d.ts +0 -20
- package/dist/node/pm/bunPackageManager.d.ts.map +0 -1
- package/dist/node/pm/detectPackageManager.d.ts +0 -3
- package/dist/node/pm/detectPackageManager.d.ts.map +0 -1
- package/dist/node/pm/index.d.ts +0 -11
- package/dist/node/pm/index.d.ts.map +0 -1
- package/dist/node/pm/isReactProject.d.ts +0 -3
- package/dist/node/pm/isReactProject.d.ts.map +0 -1
- package/dist/node/pm/npmPackageManager.d.ts +0 -20
- package/dist/node/pm/npmPackageManager.d.ts.map +0 -1
- package/dist/node/pm/pnpmPackageManager.d.ts +0 -20
- package/dist/node/pm/pnpmPackageManager.d.ts.map +0 -1
- package/dist/node/pm/registry.d.ts +0 -5
- package/dist/node/pm/registry.d.ts.map +0 -1
- package/dist/node/pm/resolveWorkspace.d.ts +0 -3
- package/dist/node/pm/resolveWorkspace.d.ts.map +0 -1
- package/dist/node/pm/runtime.d.ts +0 -2
- package/dist/node/pm/runtime.d.ts.map +0 -1
- package/dist/node/pm/workspaces.d.ts +0 -15
- package/dist/node/pm/workspaces.d.ts.map +0 -1
- package/dist/node/pm/yarnPackageManager.d.ts +0 -20
- package/dist/node/pm/yarnPackageManager.d.ts.map +0 -1
- package/dist/node/xy/build/buildCommand.d.ts +0 -3
- package/dist/node/xy/build/buildCommand.d.ts.map +0 -1
- package/dist/node/xy/build/compileCommand.d.ts +0 -3
- package/dist/node/xy/build/compileCommand.d.ts.map +0 -1
- package/dist/node/xy/build/copyAssetsCommand.d.ts +0 -3
- package/dist/node/xy/build/copyAssetsCommand.d.ts.map +0 -1
- package/dist/node/xy/build/index.d.ts +0 -3
- package/dist/node/xy/build/index.d.ts.map +0 -1
- package/dist/node/xy/build/rebuildCommand.d.ts +0 -3
- package/dist/node/xy/build/rebuildCommand.d.ts.map +0 -1
- package/dist/node/xy/build/recompileCommand.d.ts +0 -3
- package/dist/node/xy/build/recompileCommand.d.ts.map +0 -1
- package/dist/node/xy/build/tscValidateCommand.d.ts +0 -3
- package/dist/node/xy/build/tscValidateCommand.d.ts.map +0 -1
- package/dist/node/xy/common/checkCommand.d.ts +0 -3
- package/dist/node/xy/common/checkCommand.d.ts.map +0 -1
- package/dist/node/xy/common/deadCommand.d.ts +0 -3
- package/dist/node/xy/common/deadCommand.d.ts.map +0 -1
- package/dist/node/xy/common/gitignoreCommand.d.ts +0 -3
- package/dist/node/xy/common/gitignoreCommand.d.ts.map +0 -1
- package/dist/node/xy/common/gitlintCommand.d.ts +0 -3
- package/dist/node/xy/common/gitlintCommand.d.ts.map +0 -1
- package/dist/node/xy/common/index.d.ts +0 -3
- package/dist/node/xy/common/index.d.ts.map +0 -1
- package/dist/node/xy/common/licenseCommand.d.ts +0 -3
- package/dist/node/xy/common/licenseCommand.d.ts.map +0 -1
- package/dist/node/xy/common/npmignoreGenCommand.d.ts +0 -3
- package/dist/node/xy/common/npmignoreGenCommand.d.ts.map +0 -1
- package/dist/node/xy/common/orphan/cleanCommand.d.ts +0 -3
- package/dist/node/xy/common/orphan/cleanCommand.d.ts.map +0 -1
- package/dist/node/xy/common/orphan/index.d.ts +0 -3
- package/dist/node/xy/common/orphan/index.d.ts.map +0 -1
- package/dist/node/xy/common/orphan/listCommand.d.ts +0 -3
- package/dist/node/xy/common/orphan/listCommand.d.ts.map +0 -1
- package/dist/node/xy/common/packmanCommand.d.ts +0 -3
- package/dist/node/xy/common/packmanCommand.d.ts.map +0 -1
- package/dist/node/xy/common/repo/index.d.ts +0 -3
- package/dist/node/xy/common/repo/index.d.ts.map +0 -1
- package/dist/node/xy/common/repo/initCommand.d.ts +0 -3
- package/dist/node/xy/common/repo/initCommand.d.ts.map +0 -1
- package/dist/node/xy/common/repo/lintCommand.d.ts +0 -3
- package/dist/node/xy/common/repo/lintCommand.d.ts.map +0 -1
- package/dist/node/xy/common/retestCommand.d.ts +0 -3
- package/dist/node/xy/common/retestCommand.d.ts.map +0 -1
- package/dist/node/xy/common/secureCommand.d.ts +0 -3
- package/dist/node/xy/common/secureCommand.d.ts.map +0 -1
- package/dist/node/xy/common/skills/index.d.ts +0 -3
- package/dist/node/xy/common/skills/index.d.ts.map +0 -1
- package/dist/node/xy/common/testCommand.d.ts +0 -3
- package/dist/node/xy/common/testCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/addCommand.d.ts +0 -3
- package/dist/node/xy/common/work/addCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/claimCommand.d.ts +0 -3
- package/dist/node/xy/common/work/claimCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/doneCommand.d.ts +0 -3
- package/dist/node/xy/common/work/doneCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/index.d.ts +0 -3
- package/dist/node/xy/common/work/index.d.ts.map +0 -1
- package/dist/node/xy/common/work/initCommand.d.ts +0 -3
- package/dist/node/xy/common/work/initCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/listCommand.d.ts +0 -3
- package/dist/node/xy/common/work/listCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/nextCommand.d.ts +0 -3
- package/dist/node/xy/common/work/nextCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/options.d.ts +0 -5
- package/dist/node/xy/common/work/options.d.ts.map +0 -1
- package/dist/node/xy/common/work/queueCommand.d.ts +0 -3
- package/dist/node/xy/common/work/queueCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/showCommand.d.ts +0 -3
- package/dist/node/xy/common/work/showCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/triageCommand.d.ts +0 -3
- package/dist/node/xy/common/work/triageCommand.d.ts.map +0 -1
- package/dist/node/xy/common/work/updateCommand.d.ts +0 -3
- package/dist/node/xy/common/work/updateCommand.d.ts.map +0 -1
- package/dist/node/xy/deploy/deployCommand.d.ts +0 -3
- package/dist/node/xy/deploy/deployCommand.d.ts.map +0 -1
- package/dist/node/xy/deploy/index.d.ts +0 -3
- package/dist/node/xy/deploy/index.d.ts.map +0 -1
- package/dist/node/xy/deploy/publishCommand.d.ts +0 -3
- package/dist/node/xy/deploy/publishCommand.d.ts.map +0 -1
- package/dist/node/xy/index.d.ts +0 -9
- package/dist/node/xy/index.d.ts.map +0 -1
- package/dist/node/xy/install/cleanCommand.d.ts +0 -3
- package/dist/node/xy/install/cleanCommand.d.ts.map +0 -1
- package/dist/node/xy/install/index.d.ts +0 -3
- package/dist/node/xy/install/index.d.ts.map +0 -1
- package/dist/node/xy/install/installCommand.d.ts +0 -3
- package/dist/node/xy/install/installCommand.d.ts.map +0 -1
- package/dist/node/xy/install/reinstallCommand.d.ts +0 -3
- package/dist/node/xy/install/reinstallCommand.d.ts.map +0 -1
- package/dist/node/xy/install/staticsCommand.d.ts +0 -3
- package/dist/node/xy/install/staticsCommand.d.ts.map +0 -1
- package/dist/node/xy/install/upCommand.d.ts +0 -3
- package/dist/node/xy/install/upCommand.d.ts.map +0 -1
- package/dist/node/xy/install/updoCommand.d.ts +0 -3
- package/dist/node/xy/install/updoCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/apiExposureCommand.d.ts +0 -3
- package/dist/node/xy/lint/apiExposureCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/cycleCommand.d.ts +0 -3
- package/dist/node/xy/lint/cycleCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/deplintCommand.d.ts +0 -3
- package/dist/node/xy/lint/deplintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/fixCommand.d.ts +0 -3
- package/dist/node/xy/lint/fixCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/index.d.ts +0 -3
- package/dist/node/xy/lint/index.d.ts.map +0 -1
- package/dist/node/xy/lint/lint/configCommand.d.ts +0 -5
- package/dist/node/xy/lint/lint/configCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/lint/index.d.ts +0 -3
- package/dist/node/xy/lint/lint/index.d.ts.map +0 -1
- package/dist/node/xy/lint/lint/initCommand.d.ts +0 -3
- package/dist/node/xy/lint/lint/initCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/lint/runCommand.d.ts +0 -3
- package/dist/node/xy/lint/lint/runCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/lintCommand.d.ts +0 -2
- package/dist/node/xy/lint/lintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/lintlintCommand.d.ts +0 -3
- package/dist/node/xy/lint/lintlintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/nodeLintCommand.d.ts +0 -3
- package/dist/node/xy/lint/nodeLintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/publintCommand.d.ts +0 -3
- package/dist/node/xy/lint/publintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/relintCommand.d.ts +0 -3
- package/dist/node/xy/lint/relintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/republintCommand.d.ts +0 -3
- package/dist/node/xy/lint/republintCommand.d.ts.map +0 -1
- package/dist/node/xy/lint/sonarCommand.d.ts +0 -3
- package/dist/node/xy/lint/sonarCommand.d.ts.map +0 -1
- package/dist/node/xy/packageManagerWarning.d.ts +0 -4
- package/dist/node/xy/packageManagerWarning.d.ts.map +0 -1
- package/dist/node/xy/param.d.ts +0 -5
- package/dist/node/xy/param.d.ts.map +0 -1
- package/dist/node/xy/react/analyzeCommand.d.ts +0 -3
- package/dist/node/xy/react/analyzeCommand.d.ts.map +0 -1
- package/dist/node/xy/react/ejectCommand.d.ts +0 -3
- package/dist/node/xy/react/ejectCommand.d.ts.map +0 -1
- package/dist/node/xy/react/index.d.ts +0 -3
- package/dist/node/xy/react/index.d.ts.map +0 -1
- package/dist/node/xy/react/sitemapCommand.d.ts +0 -3
- package/dist/node/xy/react/sitemapCommand.d.ts.map +0 -1
- package/dist/node/xy/react/startCommand.d.ts +0 -3
- package/dist/node/xy/react/startCommand.d.ts.map +0 -1
- package/dist/node/xy/xy.d.ts +0 -20
- package/dist/node/xy/xy.d.ts.map +0 -1
- package/dist/node/xy/xyParseOptions.d.ts +0 -3
- package/dist/node/xy/xyParseOptions.d.ts.map +0 -1
- package/dist/pm/detectReact.d.ts +0 -3
- package/dist/pm/detectReact.d.ts.map +0 -1
- package/dist/xy/common/claude/checkCommand.d.ts +0 -3
- package/dist/xy/common/claude/checkCommand.d.ts.map +0 -1
- package/dist/xy/common/claude/cleanCommand.d.ts +0 -3
- package/dist/xy/common/claude/cleanCommand.d.ts.map +0 -1
- package/dist/xy/common/claude/commandsCommand.d.ts +0 -3
- package/dist/xy/common/claude/commandsCommand.d.ts.map +0 -1
- package/dist/xy/common/claude/index.d.ts +0 -3
- package/dist/xy/common/claude/index.d.ts.map +0 -1
- package/dist/xy/common/claude/initCommand.d.ts +0 -3
- package/dist/xy/common/claude/initCommand.d.ts.map +0 -1
- package/dist/xy/common/claude/rulesCommand.d.ts +0 -3
- package/dist/xy/common/claude/rulesCommand.d.ts.map +0 -1
- package/dist/xy/common/claude/settingsCommand.d.ts +0 -3
- package/dist/xy/common/claude/settingsCommand.d.ts.map +0 -1
- package/dist/xy/common/claude/skillsCommand.d.ts +0 -3
- package/dist/xy/common/claude/skillsCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/addCommand.d.ts +0 -3
- package/dist/xy/common/skills/addCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/experimentalInstallCommand.d.ts +0 -3
- package/dist/xy/common/skills/experimentalInstallCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/experimentalSyncCommand.d.ts +0 -3
- package/dist/xy/common/skills/experimentalSyncCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/findCommand.d.ts +0 -3
- package/dist/xy/common/skills/findCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/initCommand.d.ts +0 -3
- package/dist/xy/common/skills/initCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/lintCommand.d.ts +0 -3
- package/dist/xy/common/skills/lintCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/listCommand.d.ts +0 -3
- package/dist/xy/common/skills/listCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/removeCommand.d.ts +0 -3
- package/dist/xy/common/skills/removeCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/updateCommand.d.ts +0 -3
- package/dist/xy/common/skills/updateCommand.d.ts.map +0 -1
- package/dist/xy/common/skills/updoCommand.d.ts +0 -3
- package/dist/xy/common/skills/updoCommand.d.ts.map +0 -1
- package/dist/xy/install/upskillsCommand.d.ts +0 -3
- package/dist/xy/install/upskillsCommand.d.ts.map +0 -1
package/dist/bin/xy.mjs
CHANGED
|
@@ -4723,7 +4723,7 @@ function isReactProject() {
|
|
|
4723
4723
|
//#endregion
|
|
4724
4724
|
//#region src/pm/npmPackageManager.ts
|
|
4725
4725
|
function collectVersions(node, versions) {
|
|
4726
|
-
if (
|
|
4726
|
+
if (typeof node !== "object" || !Boolean(node)) return;
|
|
4727
4727
|
const value = node;
|
|
4728
4728
|
if (value.name != null && value.name.length > 0 && value.version != null && value.version.length > 0 && !versions.has(value.name)) versions.set(value.name, value.version);
|
|
4729
4729
|
const dependencies = Object.values(value.dependencies ?? {});
|
|
@@ -5202,7 +5202,7 @@ function extractPnpmVersions(data, depName) {
|
|
|
5202
5202
|
const versions = /* @__PURE__ */ new Set();
|
|
5203
5203
|
function walk(obj) {
|
|
5204
5204
|
if (Array.isArray(obj)) for (const item of obj) walk(item);
|
|
5205
|
-
else if (
|
|
5205
|
+
else if (typeof obj === "object" && Boolean(obj)) {
|
|
5206
5206
|
const record = obj;
|
|
5207
5207
|
if (typeof record.version === "string" && typeof record.from === "string" && record.from === depName) versions.add(record.version);
|
|
5208
5208
|
for (const val of Object.values(record)) walk(val);
|
|
@@ -11861,6 +11861,12 @@ const RULE_COMMANDS = {
|
|
|
11861
11861
|
includeInRoot: true,
|
|
11862
11862
|
title: "Check Rules"
|
|
11863
11863
|
},
|
|
11864
|
+
clean: {
|
|
11865
|
+
command: "clean",
|
|
11866
|
+
configKey: "clean",
|
|
11867
|
+
includeInRoot: true,
|
|
11868
|
+
title: "Clean Rules"
|
|
11869
|
+
},
|
|
11864
11870
|
cycle: {
|
|
11865
11871
|
command: "cycle",
|
|
11866
11872
|
includeInRoot: true,
|
|
@@ -12068,7 +12074,7 @@ function mergeRuleConfigs(target, source) {
|
|
|
12068
12074
|
}
|
|
12069
12075
|
function mergeCommandConfig(rootCmd, workspaceCmd, commandName) {
|
|
12070
12076
|
const configKey = canonicalRuleConfigKey(commandName);
|
|
12071
|
-
return deepMerge(rootCmd, workspaceCmd, { customMerge: (key) =>
|
|
12077
|
+
return deepMerge(rootCmd, workspaceCmd, { customMerge: (key) => key === "rules" && RULE_CONFIG_COMMAND_KEYS.has(configKey) ? mergeRuleConfigs : void 0 });
|
|
12072
12078
|
}
|
|
12073
12079
|
/**
|
|
12074
12080
|
* Loads a command-specific config merged from root and workspace levels.
|
|
@@ -20560,7 +20566,7 @@ const runStepAsync = (name, step, shouldExitOnFail = true, message) => {
|
|
|
20560
20566
|
2
|
|
20561
20567
|
] : "inherit"
|
|
20562
20568
|
}).on("close", (code) => {
|
|
20563
|
-
if (code != null && !Number.isNaN(code)
|
|
20569
|
+
if (code !== 0 && code != null && !Number.isNaN(code)) {
|
|
20564
20570
|
const argsText = Array.isArray(args) ? args.join(" ") : args;
|
|
20565
20571
|
const message = `Command Exited With Non-Zero Result [${chalk.gray(code)}] | ${chalk.yellow(command)} ${chalk.white(argsText)}`;
|
|
20566
20572
|
console.error(chalk.red(message));
|
|
@@ -21206,13 +21212,13 @@ function lookupErrorMessage(error) {
|
|
|
21206
21212
|
}
|
|
21207
21213
|
function coerceStringRecord(value) {
|
|
21208
21214
|
const out = {};
|
|
21209
|
-
if (
|
|
21215
|
+
if (typeof value !== "object" || value == null || Array.isArray(value)) return out;
|
|
21210
21216
|
for (const [key, raw] of Object.entries(value)) if (typeof raw === "string") out[key] = raw;
|
|
21211
21217
|
return out;
|
|
21212
21218
|
}
|
|
21213
21219
|
function coerceVersions(value) {
|
|
21214
21220
|
if (Array.isArray(value)) return value.filter((v) => typeof v === "string");
|
|
21215
|
-
if (value
|
|
21221
|
+
if (typeof value === "object" && value != null) return Object.keys(value);
|
|
21216
21222
|
return [];
|
|
21217
21223
|
}
|
|
21218
21224
|
function parsePackageViewJson(stdout, options = {}) {
|
|
@@ -21403,7 +21409,7 @@ function logFetchComplete(total) {
|
|
|
21403
21409
|
if (total > 0) console.log(chalk.gray(` Finished registry metadata lookup for ${total} package(s)`));
|
|
21404
21410
|
}
|
|
21405
21411
|
function writeFetchProgress(completed, total) {
|
|
21406
|
-
if (completed
|
|
21412
|
+
if (completed === total || completed % 25 === 0) process.stderr.write(`\r Fetched ${completed}/${total} package metadata records...`);
|
|
21407
21413
|
}
|
|
21408
21414
|
async function fetchAllRegistryInfoDirect(packageNames, options = {}) {
|
|
21409
21415
|
const results = /* @__PURE__ */ new Map();
|
|
@@ -23268,7 +23274,7 @@ function checkVersionSatisfaction(location, peer, requestedRange) {
|
|
|
23268
23274
|
function findDeclaredPeerVersionMismatches(name, location, peerDependencies, peerDependencyVersions, exclude) {
|
|
23269
23275
|
const results = [];
|
|
23270
23276
|
for (const peer of peerDependencies) {
|
|
23271
|
-
if ((exclude?.has(peer) ?? false)
|
|
23277
|
+
if (peer === name || (exclude?.has(peer) ?? false)) continue;
|
|
23272
23278
|
const declaredRange = peerDependencyVersions[peer];
|
|
23273
23279
|
if (!declaredRange || declaredRange === "*") continue;
|
|
23274
23280
|
const { installedVersion, satisfied: isSatisfied } = checkVersionSatisfaction(location, peer, declaredRange);
|
|
@@ -23352,7 +23358,7 @@ function findUnsatisfiedPeers({ name, location }, { dependencies, devDependencie
|
|
|
23352
23358
|
};
|
|
23353
23359
|
const unsatisfied = [];
|
|
23354
23360
|
for (const [peer, sources] of peerSources) {
|
|
23355
|
-
if ((exclude?.has(peer) ?? false)
|
|
23361
|
+
if (peer === name || (exclude?.has(peer) ?? false)) continue;
|
|
23356
23362
|
if (!(forcePeerOptional?.has(peer) ?? false) && isPeerOptionalInAll(location, peer, sources)) continue;
|
|
23357
23363
|
const finding = classifyPeer(peer, sources, ctx);
|
|
23358
23364
|
if (finding) unsatisfied.push(finding);
|
|
@@ -23370,7 +23376,7 @@ function findMismatchedSources(location, sources, peer, installedVersion) {
|
|
|
23370
23376
|
if (installedVersion == null || installedVersion.length === 0) return [];
|
|
23371
23377
|
return sources.filter((source) => {
|
|
23372
23378
|
const range = readPeerVersionRange(location, source.requiredBy, peer);
|
|
23373
|
-
if (range
|
|
23379
|
+
if (range === "*" || range == null || range.length === 0 || range.startsWith("workspace:")) return false;
|
|
23374
23380
|
try {
|
|
23375
23381
|
return !import_semver.default.satisfies(installedVersion, range, { includePrerelease: true });
|
|
23376
23382
|
} catch {
|
|
@@ -23634,7 +23640,7 @@ const DEFAULT_AEI_THRESHOLDS = {
|
|
|
23634
23640
|
probablyPeerMax: 179,
|
|
23635
23641
|
reviewMax: 119
|
|
23636
23642
|
};
|
|
23637
|
-
const RULE_LEVELS$
|
|
23643
|
+
const RULE_LEVELS$2 = /* @__PURE__ */ new Set([
|
|
23638
23644
|
"error",
|
|
23639
23645
|
"off",
|
|
23640
23646
|
"warn"
|
|
@@ -23645,8 +23651,8 @@ function isRecord$5(value) {
|
|
|
23645
23651
|
function isValidWeight(value) {
|
|
23646
23652
|
return value === "infinite" || typeof value === "number" && Number.isFinite(value) && value >= 0;
|
|
23647
23653
|
}
|
|
23648
|
-
function isRuleLevel$
|
|
23649
|
-
return typeof value === "string" && RULE_LEVELS$
|
|
23654
|
+
function isRuleLevel$5(value) {
|
|
23655
|
+
return typeof value === "string" && RULE_LEVELS$2.has(value);
|
|
23650
23656
|
}
|
|
23651
23657
|
function parseWeight(location, weight) {
|
|
23652
23658
|
if (!isValidWeight(weight)) throw new TypeError(`${location} must be a non-negative finite number or "infinite"`);
|
|
@@ -23655,7 +23661,7 @@ function parseWeight(location, weight) {
|
|
|
23655
23661
|
function parseTupleRuleSetting(location, setting) {
|
|
23656
23662
|
if (setting.length !== 2) throw new TypeError(`${location} tuple must be [level, options]`);
|
|
23657
23663
|
const [level, options] = setting;
|
|
23658
|
-
if (!isRuleLevel$
|
|
23664
|
+
if (!isRuleLevel$5(level)) throw new TypeError(`${location} level must be "error", "warn", or "off"`);
|
|
23659
23665
|
if (!isRecord$5(options)) throw new TypeError(`${location} options must be an object`);
|
|
23660
23666
|
return {
|
|
23661
23667
|
enabled: level !== "off",
|
|
@@ -23670,7 +23676,7 @@ function parseObjectRuleSetting(location, setting) {
|
|
|
23670
23676
|
"weight"
|
|
23671
23677
|
].includes(key)) throw new TypeError(`${location} has unknown option "${key}"`);
|
|
23672
23678
|
if (setting.enabled !== void 0 && typeof setting.enabled !== "boolean") throw new TypeError(`${location}.enabled must be a boolean`);
|
|
23673
|
-
if (setting.level !== void 0 && !isRuleLevel$
|
|
23679
|
+
if (setting.level !== void 0 && !isRuleLevel$5(setting.level)) throw new TypeError(`${location}.level must be "error", "warn", or "off"`);
|
|
23674
23680
|
const level = setting.level;
|
|
23675
23681
|
return {
|
|
23676
23682
|
enabled: level === void 0 ? setting.enabled : level !== "off",
|
|
@@ -23680,7 +23686,7 @@ function parseObjectRuleSetting(location, setting) {
|
|
|
23680
23686
|
}
|
|
23681
23687
|
function parseRuleSetting(location, setting) {
|
|
23682
23688
|
if (typeof setting === "boolean") return { enabled: setting };
|
|
23683
|
-
if (isRuleLevel$
|
|
23689
|
+
if (isRuleLevel$5(setting)) return {
|
|
23684
23690
|
enabled: setting !== "off",
|
|
23685
23691
|
level: setting
|
|
23686
23692
|
};
|
|
@@ -24732,7 +24738,7 @@ function getExposureFindings({ entryFiles, fileLabel, program }) {
|
|
|
24732
24738
|
});
|
|
24733
24739
|
}
|
|
24734
24740
|
function reportUsage(usage, directRuleId, node, directEvidence, genericEvidence, structuralRuleId) {
|
|
24735
|
-
for (const [dependency, typeUsage] of usage) if (
|
|
24741
|
+
for (const [dependency, typeUsage] of usage) if (structuralRuleId !== void 0 && typeUsage.structural) report(structuralRuleId, dependency, node, `exported API returns a structural type from ${dependency}`);
|
|
24736
24742
|
else if (typeUsage.kind === "direct") report(directRuleId, dependency, node, directEvidence(dependency));
|
|
24737
24743
|
else report("aei.exposure.generic-parameter", dependency, node, genericEvidence(dependency));
|
|
24738
24744
|
}
|
|
@@ -24784,7 +24790,7 @@ function getExposureFindings({ entryFiles, fileLabel, program }) {
|
|
|
24784
24790
|
const directDependencies = [...usage].filter(([, typeUsage]) => typeUsage.kind === "direct").map(([dependency]) => dependency);
|
|
24785
24791
|
for (const dependency of directDependencies) report("aei.exposure.exported-value", dependency, declaration, `exported runtime value \`${name}\` has a type originating in ${dependency}`);
|
|
24786
24792
|
for (const [dependency, typeUsage] of usage) if (typeUsage.kind === "generic") report("aei.exposure.generic-parameter", dependency, declaration, `exported value \`${name}\` uses ${dependency} as a generic argument`);
|
|
24787
|
-
if (
|
|
24793
|
+
if (initializer !== void 0 && directDependencies.length === 0 && ts.isCallExpression(initializer)) {
|
|
24788
24794
|
const resolved = resolveAlias(checker, checker.getSymbolAtLocation(initializer.expression));
|
|
24789
24795
|
for (const dependency of symbolDependencies(resolved)) report("aei.exposure.exported-constant", dependency, declaration, `exported constant \`${name}\` is produced by a ${dependency} factory`);
|
|
24790
24796
|
}
|
|
@@ -24961,6 +24967,24 @@ function getImportedPackages(program, workspaceDir) {
|
|
|
24961
24967
|
};
|
|
24962
24968
|
}
|
|
24963
24969
|
//#endregion
|
|
24970
|
+
//#region src/actions/api-exposure/analyzer/placement.ts
|
|
24971
|
+
/**
|
|
24972
|
+
* Whether deplint can require a local runtime-section placement for this
|
|
24973
|
+
* assessment. A dependency already listed in a runtime section is locally
|
|
24974
|
+
* owned. Otherwise it is actionable only when this package names it directly,
|
|
24975
|
+
* an override explicitly claims it, or `peerForwarding: "always"` deliberately
|
|
24976
|
+
* forwards its inherited peer contract. Type-checker findings that merely
|
|
24977
|
+
* trace through another package remain useful exposure evidence, but that
|
|
24978
|
+
* provider owns their manifest placement.
|
|
24979
|
+
*/
|
|
24980
|
+
function isPlacementActionable({ config, currentSection, dependency, importedPackages, recommendationSource, requiredPeerSources }) {
|
|
24981
|
+
if (currentSection === "dependencies" || currentSection === "dependencies+peerDependencies") return true;
|
|
24982
|
+
if (recommendationSource === "override" || recommendationSource === "workspace-internal") return true;
|
|
24983
|
+
if (importedPackages === void 0) return true;
|
|
24984
|
+
if (importedPackages.value.has(dependency) || importedPackages.typeOnly.has(dependency)) return true;
|
|
24985
|
+
return config.peerForwarding === "always" && requiredPeerSources.has(dependency);
|
|
24986
|
+
}
|
|
24987
|
+
//#endregion
|
|
24964
24988
|
//#region src/actions/api-exposure/analyzer/program.ts
|
|
24965
24989
|
function createSharedProgramCache() {
|
|
24966
24990
|
return { sourceFiles: /* @__PURE__ */ new Map() };
|
|
@@ -25258,6 +25282,14 @@ function assessDependency({ config, dependency, importedPackages, isSelfOrIntern
|
|
|
25258
25282
|
dependency,
|
|
25259
25283
|
findings,
|
|
25260
25284
|
installStrategy,
|
|
25285
|
+
placementActionable: isPlacementActionable({
|
|
25286
|
+
config,
|
|
25287
|
+
currentSection: currentSectionOf(dependency, sections),
|
|
25288
|
+
dependency,
|
|
25289
|
+
importedPackages,
|
|
25290
|
+
recommendationSource,
|
|
25291
|
+
requiredPeerSources
|
|
25292
|
+
}),
|
|
25261
25293
|
recommendation,
|
|
25262
25294
|
recommendationSource,
|
|
25263
25295
|
treeShakingModifier: score.treeShakingModifier
|
|
@@ -25379,7 +25411,8 @@ function bandIndex(band) {
|
|
|
25379
25411
|
* when both `dependencies` and `peerDependencies` list the package.
|
|
25380
25412
|
*/
|
|
25381
25413
|
function isMismatch(assessment) {
|
|
25382
|
-
const { currentSection, recommendation } = assessment;
|
|
25414
|
+
const { currentSection, placementActionable, recommendation } = assessment;
|
|
25415
|
+
if (placementActionable === false) return false;
|
|
25383
25416
|
if (recommendation === "review") return false;
|
|
25384
25417
|
if (recommendation === "peer-with-default") return currentSection !== "dependencies+peerDependencies";
|
|
25385
25418
|
if (bandIndex(recommendation) > bandIndex("review")) return currentSection !== "peerDependencies";
|
|
@@ -25402,7 +25435,8 @@ function renderAssessment(assessment, verbose) {
|
|
|
25402
25435
|
const mismatch = isMismatch(assessment) ? ` ${chalk.red("MISMATCH")}` : "";
|
|
25403
25436
|
const source = assessment.recommendationSource === "score" ? "" : ` [${assessment.recommendationSource}]`;
|
|
25404
25437
|
const strategy = assessment.installStrategy === void 0 ? "" : chalk.dim(` strategy=${assessment.installStrategy}`);
|
|
25405
|
-
|
|
25438
|
+
const placement = assessment.placementActionable === false ? chalk.dim(" placement=transitive") : "";
|
|
25439
|
+
console.log(` ${chalk.bold(assessment.dependency)} ${formatScore(assessment)} → ${color(assessment.recommendation)} (currently: ${assessment.currentSection})${source}${strategy}${placement}${mismatch}`);
|
|
25406
25440
|
if (!(verbose || isMismatch(assessment) || assessment.recommendation === "review")) return;
|
|
25407
25441
|
for (const finding of assessment.findings) {
|
|
25408
25442
|
const weight = finding.infinite ? " ∞" : `+${finding.weight}`.padStart(4);
|
|
@@ -25497,7 +25531,7 @@ function collectDiagnostics(results, failOn) {
|
|
|
25497
25531
|
}
|
|
25498
25532
|
const apiExposure = async ({ dep, failOn, format, minBand, pkg, verbose, workspaces: inputWorkspaces }) => {
|
|
25499
25533
|
const effectiveFormat = format ?? (isJsonMode() ? "json" : "human");
|
|
25500
|
-
const targetPackage = typeof pkg === "string" && pkg
|
|
25534
|
+
const targetPackage = typeof pkg === "string" && pkg !== "undefined" && pkg.length > 0 ? pkg : void 0;
|
|
25501
25535
|
const { targetWorkspaces, workspaceNames } = resolveTargetWorkspaces$1(targetPackage, inputWorkspaces);
|
|
25502
25536
|
if (targetWorkspaces.length === 0) {
|
|
25503
25537
|
console.error(chalk.red(`Workspace not found: ${targetPackage}`));
|
|
@@ -25511,7 +25545,7 @@ const apiExposure = async ({ dep, failOn, format, minBand, pkg, verbose, workspa
|
|
|
25511
25545
|
}
|
|
25512
25546
|
const results = await analyzeWorkspaces(targetWorkspaces, workspaceNames, createSharedProgramCache(), dep, verbose);
|
|
25513
25547
|
const { errorAssessments, mismatches, warningAssessments } = collectDiagnostics(results, failOn);
|
|
25514
|
-
if (
|
|
25548
|
+
if (effectiveFormat === "human" && !isJsonMode()) {
|
|
25515
25549
|
renderHumanApiExposure(results, {
|
|
25516
25550
|
minBand,
|
|
25517
25551
|
verbose
|
|
@@ -27112,16 +27146,16 @@ const ignoredInputDirs = /* @__PURE__ */ new Set([
|
|
|
27112
27146
|
]);
|
|
27113
27147
|
const ignoredInputFiles = /* @__PURE__ */ new Set([".eslintcache"]);
|
|
27114
27148
|
const outputDirs = ["build", "dist"];
|
|
27115
|
-
function toPosix(value) {
|
|
27149
|
+
function toPosix$1(value) {
|
|
27116
27150
|
return value.split(PATH.sep).join("/");
|
|
27117
27151
|
}
|
|
27118
27152
|
function normalizeLocation(value) {
|
|
27119
|
-
const normalized = toPosix(value).replace(/\/$/u, "");
|
|
27153
|
+
const normalized = toPosix$1(value).replace(/\/$/u, "");
|
|
27120
27154
|
return normalized === "" ? "." : normalized;
|
|
27121
27155
|
}
|
|
27122
27156
|
function stableValue(value) {
|
|
27123
27157
|
if (Array.isArray(value)) return value.map(stableValue);
|
|
27124
|
-
if (
|
|
27158
|
+
if (typeof value === "object" && Boolean(value)) {
|
|
27125
27159
|
const entries = Object.entries(value).toSorted(([a], [b]) => a.localeCompare(b)).map(([key, entryValue]) => [key, stableValue(entryValue)]);
|
|
27126
27160
|
return Object.fromEntries(entries);
|
|
27127
27161
|
}
|
|
@@ -27144,7 +27178,7 @@ function readPackageJson$6(rootDir, workspace) {
|
|
|
27144
27178
|
return readJsonFile(PATH.resolve(rootDir, workspace.location, "package.json"));
|
|
27145
27179
|
}
|
|
27146
27180
|
function isStringRecord(value) {
|
|
27147
|
-
if (value
|
|
27181
|
+
if (typeof value !== "object" || value == null) return false;
|
|
27148
27182
|
return Object.values(value).every((entry) => typeof entry === "string");
|
|
27149
27183
|
}
|
|
27150
27184
|
function packageDeps(pkg, field) {
|
|
@@ -27194,7 +27228,7 @@ function collectFiles(dir, baseDir = dir) {
|
|
|
27194
27228
|
if (!entry.isFile() && !entry.isSymbolicLink()) continue;
|
|
27195
27229
|
if (ignoredInputFiles.has(entry.name)) continue;
|
|
27196
27230
|
const relativePath = PATH.relative(baseDir, PATH.join(dir, entry.name));
|
|
27197
|
-
files.push(toPosix(relativePath));
|
|
27231
|
+
files.push(toPosix$1(relativePath));
|
|
27198
27232
|
}
|
|
27199
27233
|
return files.toSorted((a, b) => a.localeCompare(b));
|
|
27200
27234
|
}
|
|
@@ -27249,9 +27283,9 @@ function readPnpmLockfileImporters(rootDir, pm) {
|
|
|
27249
27283
|
if (!existsSync(lockfilePath)) return {};
|
|
27250
27284
|
try {
|
|
27251
27285
|
const parsed = import_dist.parse(readFileSync(lockfilePath, "utf8"));
|
|
27252
|
-
if (
|
|
27286
|
+
if (typeof parsed !== "object" || !Boolean(parsed)) return {};
|
|
27253
27287
|
const importers = parsed.importers;
|
|
27254
|
-
if (
|
|
27288
|
+
if (typeof importers !== "object" || !Boolean(importers) || Array.isArray(importers)) return {};
|
|
27255
27289
|
const hashes = {};
|
|
27256
27290
|
const sortedImporters = Object.entries(importers).toSorted(([a], [b]) => a.localeCompare(b));
|
|
27257
27291
|
for (const [name, value] of sortedImporters) hashes[normalizeLocation(name)] = hashJson(value);
|
|
@@ -27644,7 +27678,7 @@ async function runSharedValidate(targetWorkspaces, verbose) {
|
|
|
27644
27678
|
*/
|
|
27645
27679
|
const tscValidate = async ({ pkg, verbose, workspaces: inputWorkspaces }) => {
|
|
27646
27680
|
const pm = getPackageManager();
|
|
27647
|
-
const targetPackage = typeof pkg === "string" && pkg
|
|
27681
|
+
const targetPackage = typeof pkg === "string" && pkg !== "undefined" && pkg.length > 0 ? pkg : void 0;
|
|
27648
27682
|
const targetWorkspace = targetPackage === void 0 ? void 0 : pm.findWorkspace(targetPackage);
|
|
27649
27683
|
const targetWorkspaces = targetPackage === void 0 ? inputWorkspaces ?? pm.listWorkspaces() : targetWorkspace ? [targetWorkspace] : [];
|
|
27650
27684
|
if (targetWorkspaces.length === 0) {
|
|
@@ -27892,7 +27926,7 @@ async function runWorkspaceScriptsTopologically(label, pm, workspaces, fields, s
|
|
|
27892
27926
|
let totalStatus = 0;
|
|
27893
27927
|
return await new Promise((resolve) => {
|
|
27894
27928
|
const finishIfDone = () => {
|
|
27895
|
-
if (
|
|
27929
|
+
if (active === 0 && (isStopped || completed === workspaces.length)) {
|
|
27896
27930
|
if (!isStopped && ready.length === 0 && completed < workspaces.length) {
|
|
27897
27931
|
console.error(chalk.red(`${label}: workspace dependency cycle detected`));
|
|
27898
27932
|
resolve(totalStatus + 1);
|
|
@@ -27901,7 +27935,7 @@ async function runWorkspaceScriptsTopologically(label, pm, workspaces, fields, s
|
|
|
27901
27935
|
resolve(totalStatus);
|
|
27902
27936
|
return true;
|
|
27903
27937
|
}
|
|
27904
|
-
if (!isStopped &&
|
|
27938
|
+
if (!isStopped && active === 0 && ready.length === 0 && completed < workspaces.length) {
|
|
27905
27939
|
console.error(chalk.red(`${label}: workspace dependency cycle detected`));
|
|
27906
27940
|
resolve(totalStatus + 1);
|
|
27907
27941
|
return true;
|
|
@@ -28183,7 +28217,7 @@ const BUILT_IN_RULE_OPTION_KEYS = {
|
|
|
28183
28217
|
function isRecord$4(value) {
|
|
28184
28218
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
28185
28219
|
}
|
|
28186
|
-
function isRuleLevel$
|
|
28220
|
+
function isRuleLevel$4(value) {
|
|
28187
28221
|
return typeof value === "string" && VALID_RULE_LEVELS$1.has(value);
|
|
28188
28222
|
}
|
|
28189
28223
|
function severityFromLevel$1(level) {
|
|
@@ -28206,7 +28240,7 @@ function warnDeprecatedDeplintRuleId(ruleId, canonicalRuleId) {
|
|
|
28206
28240
|
}
|
|
28207
28241
|
function parseRuleConfig$1(ruleId, value) {
|
|
28208
28242
|
if (typeof value === "string") {
|
|
28209
|
-
if (!isRuleLevel$
|
|
28243
|
+
if (!isRuleLevel$4(value)) throw new TypeError(`${formatRuleConfigLocation$1(ruleId)} must be one of "off", "warn", or "error"`);
|
|
28210
28244
|
return {
|
|
28211
28245
|
level: value,
|
|
28212
28246
|
options: {}
|
|
@@ -28215,7 +28249,7 @@ function parseRuleConfig$1(ruleId, value) {
|
|
|
28215
28249
|
if (Array.isArray(value)) {
|
|
28216
28250
|
if (value.length !== 2) throw new TypeError(`${formatRuleConfigLocation$1(ruleId)} tuple must be [level, options]`);
|
|
28217
28251
|
const level = value[0];
|
|
28218
|
-
if (!isRuleLevel$
|
|
28252
|
+
if (!isRuleLevel$4(level)) throw new TypeError(`${formatRuleConfigLocation$1(ruleId)} level must be one of "off", "warn", or "error"`);
|
|
28219
28253
|
const options = value[1];
|
|
28220
28254
|
if (!isRecord$4(options)) throw new TypeError(`${formatRuleConfigLocation$1(ruleId)} options must be an object`);
|
|
28221
28255
|
return {
|
|
@@ -29650,7 +29684,7 @@ function findUnlistedDependencies(name, dependencies, devDependencies, peerDepen
|
|
|
29650
29684
|
//#region src/actions/deplint/checkPackage/getUnlistedDevDependencies.ts
|
|
29651
29685
|
function findUnlistedDevDeps(name, dependencies, devDependencies, peerDependencies, externalAllImports, distImports, externalDistTypeImports) {
|
|
29652
29686
|
const results = [];
|
|
29653
|
-
for (const imp of externalAllImports) if (!distImports.includes(imp) && !externalDistTypeImports.includes(imp) &&
|
|
29687
|
+
for (const imp of externalAllImports) if (imp !== name && !distImports.includes(imp) && !externalDistTypeImports.includes(imp) && !dependencies.includes(imp) && !dependencies.includes(`@types/${imp}`) && !peerDependencies.includes(imp) && !peerDependencies.includes(`@types/${imp}`) && !devDependencies.includes(imp) && !devDependencies.includes(`@types/${imp}`) && !builtinModules.includes(imp) && !isSatisfiedByTsScriptsVariant(imp, [
|
|
29654
29688
|
...dependencies,
|
|
29655
29689
|
...devDependencies,
|
|
29656
29690
|
...peerDependencies
|
|
@@ -31769,7 +31803,7 @@ function resolveTargetWorkspaces(targetPackage, inputWorkspaces) {
|
|
|
31769
31803
|
}
|
|
31770
31804
|
const deplint = async ({ pkg, classifier, deps, devDeps, fix, peerDeps, profile, verbose, cliExclude, format, jobs, workspaces: inputWorkspaces }) => {
|
|
31771
31805
|
const effectiveFormat = format ?? (isJsonMode() ? "json" : "human");
|
|
31772
|
-
const targetPackage = typeof pkg === "string" && pkg
|
|
31806
|
+
const targetPackage = typeof pkg === "string" && pkg !== "undefined" && pkg.length > 0 ? pkg : void 0;
|
|
31773
31807
|
const { targetWorkspaces, workspaceNames } = resolveTargetWorkspaces(targetPackage, inputWorkspaces);
|
|
31774
31808
|
if (targetPackage === void 0 && inputWorkspaces !== void 0 && targetWorkspaces.length === 0) return emptyResult$7();
|
|
31775
31809
|
if (targetWorkspaces.length === 0) return missingWorkspaceResult(targetPackage);
|
|
@@ -32277,7 +32311,7 @@ function countLintableSourceFiles(packageDir, isRootWorkspace) {
|
|
|
32277
32311
|
for (const entry of entries) {
|
|
32278
32312
|
if (count >= MAX_FILES_TO_COUNT) return;
|
|
32279
32313
|
const name = entry.name;
|
|
32280
|
-
if (name
|
|
32314
|
+
if (name !== ".config" && name.startsWith(".")) {}
|
|
32281
32315
|
if (entry.isDirectory()) {
|
|
32282
32316
|
if (IGNORED_DIR_NAMES.has(name)) continue;
|
|
32283
32317
|
if (isRootWorkspace && depth === 0 && name === "packages") continue;
|
|
@@ -32320,7 +32354,7 @@ function classifyLintPackage(rootDir, workspace, allWorkspaces, options = {}) {
|
|
|
32320
32354
|
mode: "full",
|
|
32321
32355
|
sourceFiles
|
|
32322
32356
|
};
|
|
32323
|
-
if (options.skipEmpty !== false
|
|
32357
|
+
if (sourceFiles === 0 && options.skipEmpty !== false) return {
|
|
32324
32358
|
mode: "skip",
|
|
32325
32359
|
reason: "no lintable source files",
|
|
32326
32360
|
sourceFiles
|
|
@@ -33104,21 +33138,407 @@ const lintAllPackages = ({ fix = false } = {}) => {
|
|
|
33104
33138
|
]]]);
|
|
33105
33139
|
};
|
|
33106
33140
|
//#endregion
|
|
33141
|
+
//#region src/actions/package/cleanGitignore.ts
|
|
33142
|
+
function normalizeRel(rootDir, absPath) {
|
|
33143
|
+
return PATH.relative(PATH.resolve(rootDir), PATH.resolve(absPath)).split(PATH.sep).join("/");
|
|
33144
|
+
}
|
|
33145
|
+
function runGit(rootDir, args) {
|
|
33146
|
+
const result = spawnSync("git", [
|
|
33147
|
+
"-C",
|
|
33148
|
+
rootDir,
|
|
33149
|
+
...args
|
|
33150
|
+
], {
|
|
33151
|
+
encoding: "utf8",
|
|
33152
|
+
maxBuffer: 32 * 1024 * 1024
|
|
33153
|
+
});
|
|
33154
|
+
return {
|
|
33155
|
+
status: result.status,
|
|
33156
|
+
stderr: result.stderr ?? "",
|
|
33157
|
+
stdout: result.stdout ?? ""
|
|
33158
|
+
};
|
|
33159
|
+
}
|
|
33160
|
+
/**
|
|
33161
|
+
* Default backend using `git check-ignore` / `git ls-files`. Respects nested
|
|
33162
|
+
* `.gitignore` files and global excludes the same way Git does.
|
|
33163
|
+
*/
|
|
33164
|
+
const gitCleanGitignoreBackend = {
|
|
33165
|
+
isGitRepo(rootDir) {
|
|
33166
|
+
const result = runGit(rootDir, ["rev-parse", "--is-inside-work-tree"]);
|
|
33167
|
+
return result.status === 0 && result.stdout.trim() === "true";
|
|
33168
|
+
},
|
|
33169
|
+
isIgnored(rootDir, absPath) {
|
|
33170
|
+
const rel = normalizeRel(rootDir, absPath);
|
|
33171
|
+
if (rel === "" || rel.startsWith("..")) return false;
|
|
33172
|
+
return runGit(rootDir, [
|
|
33173
|
+
"check-ignore",
|
|
33174
|
+
"-q",
|
|
33175
|
+
"--",
|
|
33176
|
+
rel
|
|
33177
|
+
]).status === 0;
|
|
33178
|
+
},
|
|
33179
|
+
listIgnoredUnder(rootDir, packageDir) {
|
|
33180
|
+
const root = PATH.resolve(rootDir);
|
|
33181
|
+
const pkg = PATH.resolve(packageDir);
|
|
33182
|
+
const packageRel = PATH.relative(root, pkg).split(PATH.sep).join("/");
|
|
33183
|
+
const result = runGit(root, [
|
|
33184
|
+
"ls-files",
|
|
33185
|
+
"--others",
|
|
33186
|
+
"--ignored",
|
|
33187
|
+
"--exclude-standard",
|
|
33188
|
+
"--directory",
|
|
33189
|
+
"-z",
|
|
33190
|
+
"--",
|
|
33191
|
+
packageRel === "" ? "." : packageRel
|
|
33192
|
+
]);
|
|
33193
|
+
if (result.status !== 0) return [];
|
|
33194
|
+
const paths = [];
|
|
33195
|
+
for (const entry of result.stdout.split("\0")) {
|
|
33196
|
+
if (entry.length === 0) continue;
|
|
33197
|
+
const rel = entry.endsWith("/") ? entry.slice(0, -1) : entry;
|
|
33198
|
+
paths.push(PATH.resolve(root, rel));
|
|
33199
|
+
}
|
|
33200
|
+
return paths;
|
|
33201
|
+
}
|
|
33202
|
+
};
|
|
33203
|
+
/** Batch-check which absolute paths are gitignored. */
|
|
33204
|
+
function filterGitIgnoredPaths(rootDir, absPaths, backend = gitCleanGitignoreBackend) {
|
|
33205
|
+
const ignored = [];
|
|
33206
|
+
const notIgnored = [];
|
|
33207
|
+
for (const absPath of absPaths) if (backend.isIgnored(rootDir, absPath)) ignored.push(absPath);
|
|
33208
|
+
else notIgnored.push(absPath);
|
|
33209
|
+
return {
|
|
33210
|
+
ignored,
|
|
33211
|
+
notIgnored
|
|
33212
|
+
};
|
|
33213
|
+
}
|
|
33214
|
+
//#endregion
|
|
33215
|
+
//#region src/actions/package/cleanPatterns.ts
|
|
33216
|
+
/**
|
|
33217
|
+
* True when `candidate` is strictly inside `rootDir` (not equal to it and not
|
|
33218
|
+
* outside it). Used so clean never deletes the repo root itself or anything
|
|
33219
|
+
* above it.
|
|
33220
|
+
*/
|
|
33221
|
+
function isStrictlyInsideRoot(rootDir, candidate) {
|
|
33222
|
+
const root = PATH.resolve(rootDir);
|
|
33223
|
+
const resolved = PATH.resolve(candidate);
|
|
33224
|
+
const relative = PATH.relative(root, resolved);
|
|
33225
|
+
return relative.length > 0 && relative !== ".." && !relative.startsWith(`..${PATH.sep}`) && !PATH.isAbsolute(relative);
|
|
33226
|
+
}
|
|
33227
|
+
/**
|
|
33228
|
+
* Resolve clean patterns relative to `baseDir` and ensure every resolved path
|
|
33229
|
+
* stays strictly inside `rootDir` (the monorepo root).
|
|
33230
|
+
*
|
|
33231
|
+
* - Absolute patterns are rejected (must be package-relative).
|
|
33232
|
+
* - Empty / whitespace-only patterns are rejected.
|
|
33233
|
+
* - Patterns that resolve outside or to the root itself throw.
|
|
33234
|
+
*
|
|
33235
|
+
* Returns absolute paths/globs safe to pass to `deleteGlob`.
|
|
33236
|
+
*/
|
|
33237
|
+
function resolveSafeCleanPatterns(patterns, baseDir, rootDir) {
|
|
33238
|
+
const root = PATH.resolve(rootDir);
|
|
33239
|
+
const base = PATH.resolve(baseDir);
|
|
33240
|
+
const resolvedPatterns = [];
|
|
33241
|
+
for (const pattern of patterns) {
|
|
33242
|
+
if (typeof pattern !== "string" || pattern.trim().length === 0) throw new Error("Clean pattern must be a non-empty string");
|
|
33243
|
+
if (PATH.isAbsolute(pattern)) throw new Error(`Clean pattern must be relative to the package (absolute paths are not allowed): "${pattern}"`);
|
|
33244
|
+
const resolved = PATH.resolve(base, pattern);
|
|
33245
|
+
if (!isStrictlyInsideRoot(root, resolved)) throw new Error(`Clean pattern escapes repository root: "${pattern}" (resolved to "${resolved}", root "${root}")`);
|
|
33246
|
+
resolvedPatterns.push(resolved);
|
|
33247
|
+
}
|
|
33248
|
+
return resolvedPatterns;
|
|
33249
|
+
}
|
|
33250
|
+
//#endregion
|
|
33251
|
+
//#region src/actions/package/cleanRules.ts
|
|
33252
|
+
const RULE_LEVELS$1 = /* @__PURE__ */ new Set([
|
|
33253
|
+
"error",
|
|
33254
|
+
"off",
|
|
33255
|
+
"warn"
|
|
33256
|
+
]);
|
|
33257
|
+
function isRuleLevel$3(value) {
|
|
33258
|
+
return typeof value === "string" && RULE_LEVELS$1.has(value);
|
|
33259
|
+
}
|
|
33260
|
+
function levelFromObject(location, setting, defaultLevel) {
|
|
33261
|
+
if (setting.level !== void 0) {
|
|
33262
|
+
if (!isRuleLevel$3(setting.level)) throw new TypeError(`${location}.level must be "error", "warn", or "off"`);
|
|
33263
|
+
return setting.level;
|
|
33264
|
+
}
|
|
33265
|
+
if (setting.enabled !== void 0) {
|
|
33266
|
+
if (typeof setting.enabled !== "boolean") throw new TypeError(`${location}.enabled must be a boolean`);
|
|
33267
|
+
return setting.enabled ? defaultLevel : "off";
|
|
33268
|
+
}
|
|
33269
|
+
throw new TypeError(`${location} must be a rule level, boolean, [level, options], or { level?, enabled? } object`);
|
|
33270
|
+
}
|
|
33271
|
+
/**
|
|
33272
|
+
* Local parse of rule level settings — kept here to avoid a circular import
|
|
33273
|
+
* through `ruleRunner` → `package/index` → `cleanRules`.
|
|
33274
|
+
*/
|
|
33275
|
+
function parseCleanRuleLevel(location, setting, defaultLevel) {
|
|
33276
|
+
if (setting === void 0) return defaultLevel;
|
|
33277
|
+
if (typeof setting === "boolean") return setting ? "warn" : "off";
|
|
33278
|
+
if (isRuleLevel$3(setting)) return setting;
|
|
33279
|
+
if (Array.isArray(setting) && setting.length > 0 && isRuleLevel$3(setting[0])) return setting[0];
|
|
33280
|
+
if (typeof setting === "object" && setting !== null && !Array.isArray(setting)) return levelFromObject(location, setting, defaultLevel);
|
|
33281
|
+
throw new TypeError(`${location} must be a rule level, boolean, [level, options], or { level?, enabled? } object`);
|
|
33282
|
+
}
|
|
33283
|
+
/** Hard safety rules — always enforced; cannot be disabled via config. */
|
|
33284
|
+
const CLEAN_HARD_RULES = [{
|
|
33285
|
+
description: "Patterns must resolve strictly inside the monorepo root (never the root itself or outside it)",
|
|
33286
|
+
id: "clean.inside-root"
|
|
33287
|
+
}, {
|
|
33288
|
+
description: "Patterns must be non-empty and package-relative (absolute paths are rejected)",
|
|
33289
|
+
id: "clean.relative-pattern"
|
|
33290
|
+
}];
|
|
33291
|
+
/**
|
|
33292
|
+
* Configurable clean rules. Levels can be set in `commands.clean.rules`.
|
|
33293
|
+
*/
|
|
33294
|
+
const CLEAN_CONFIGURABLE_RULES = [{
|
|
33295
|
+
defaultLevel: "error",
|
|
33296
|
+
description: "Only delete paths that are ignored by .gitignore (configured patterns; builtins and include bypass this)",
|
|
33297
|
+
id: "clean.gitignored-only"
|
|
33298
|
+
}, {
|
|
33299
|
+
defaultLevel: "off",
|
|
33300
|
+
description: "Also delete every path under the package that is matched by .gitignore",
|
|
33301
|
+
id: "clean.gitignored-all"
|
|
33302
|
+
}];
|
|
33303
|
+
const CONFIGURABLE_RULE_IDS = new Set(CLEAN_CONFIGURABLE_RULES.map((rule) => rule.id));
|
|
33304
|
+
const HARD_RULE_IDS = new Set(CLEAN_HARD_RULES.map((rule) => rule.id));
|
|
33305
|
+
/** Immutable exclude entries — always skipped by clean, cannot be overridden. */
|
|
33306
|
+
const CLEAN_IMMUTABLE_EXCLUDE = [
|
|
33307
|
+
".git",
|
|
33308
|
+
"**/.git",
|
|
33309
|
+
"**/.git/**"
|
|
33310
|
+
];
|
|
33311
|
+
/**
|
|
33312
|
+
* Default exclude entries applied in addition to config (and immutable entries).
|
|
33313
|
+
* Prevents `clean.gitignored-all` from wiping install trees by default.
|
|
33314
|
+
*/
|
|
33315
|
+
const CLEAN_DEFAULT_EXCLUDE = [
|
|
33316
|
+
"node_modules",
|
|
33317
|
+
"**/node_modules",
|
|
33318
|
+
"**/node_modules/**"
|
|
33319
|
+
];
|
|
33320
|
+
function isCleanRuleEnabled(level) {
|
|
33321
|
+
return level !== "off";
|
|
33322
|
+
}
|
|
33323
|
+
function defaultLevelForRule(ruleId) {
|
|
33324
|
+
return CLEAN_CONFIGURABLE_RULES.find((rule) => rule.id === ruleId)?.defaultLevel ?? "off";
|
|
33325
|
+
}
|
|
33326
|
+
/**
|
|
33327
|
+
* Resolve configurable clean rule levels from config. Throws if the config
|
|
33328
|
+
* references hard (non-configurable) rules or unknown rule ids.
|
|
33329
|
+
*/
|
|
33330
|
+
function resolveCleanRules(config) {
|
|
33331
|
+
const rules = config?.rules ?? {};
|
|
33332
|
+
for (const ruleId of Object.keys(rules)) {
|
|
33333
|
+
if (HARD_RULE_IDS.has(ruleId)) throw new TypeError(`commands.clean.rules["${ruleId}"] cannot be configured — hard safety rules are always enforced`);
|
|
33334
|
+
if (!CONFIGURABLE_RULE_IDS.has(ruleId)) throw new TypeError(`Unknown clean rule "${ruleId}" in commands.clean.rules. Configurable rules: ${[...CONFIGURABLE_RULE_IDS].join(", ")}`);
|
|
33335
|
+
}
|
|
33336
|
+
const level = (ruleId, setting) => {
|
|
33337
|
+
return parseCleanRuleLevel(`commands.clean.rules["${ruleId}"]`, setting, defaultLevelForRule(ruleId));
|
|
33338
|
+
};
|
|
33339
|
+
return {
|
|
33340
|
+
gitignoredAll: level("clean.gitignored-all", rules["clean.gitignored-all"]),
|
|
33341
|
+
gitignoredOnly: level("clean.gitignored-only", rules["clean.gitignored-only"])
|
|
33342
|
+
};
|
|
33343
|
+
}
|
|
33344
|
+
/** Merge immutable + default + config exclude patterns (deduped, order preserved). */
|
|
33345
|
+
function resolveCleanExclude(config) {
|
|
33346
|
+
const merged = [
|
|
33347
|
+
...CLEAN_IMMUTABLE_EXCLUDE,
|
|
33348
|
+
...CLEAN_DEFAULT_EXCLUDE,
|
|
33349
|
+
...config?.exclude ?? []
|
|
33350
|
+
];
|
|
33351
|
+
return [...new Set(merged)];
|
|
33352
|
+
}
|
|
33353
|
+
function uniqueStrings(values) {
|
|
33354
|
+
if (values === void 0 || values.length === 0) return [];
|
|
33355
|
+
return [...new Set(values)];
|
|
33356
|
+
}
|
|
33357
|
+
function resolveCleanInclude(config) {
|
|
33358
|
+
return uniqueStrings(config?.include);
|
|
33359
|
+
}
|
|
33360
|
+
function resolveCleanPatterns(config) {
|
|
33361
|
+
return uniqueStrings(config?.patterns);
|
|
33362
|
+
}
|
|
33363
|
+
//#endregion
|
|
33364
|
+
//#region src/actions/package/cleanPlan.ts
|
|
33365
|
+
init_index_min();
|
|
33366
|
+
/** Built-in clean targets — always cleaned (bypass gitignored-only). */
|
|
33367
|
+
const BUILTIN_CLEAN_PATTERNS = ["dist", "build"];
|
|
33368
|
+
function toPosix(relativePath) {
|
|
33369
|
+
return relativePath.split(PATH.sep).join("/");
|
|
33370
|
+
}
|
|
33371
|
+
function packageRelative(packageDir, absPath) {
|
|
33372
|
+
return toPosix(PATH.relative(packageDir, absPath));
|
|
33373
|
+
}
|
|
33374
|
+
/**
|
|
33375
|
+
* Expand absolute path/glob patterns to filesystem entries. When a pattern
|
|
33376
|
+
* matches nothing, the pattern itself is kept so callers can still pass it to
|
|
33377
|
+
* delete (no-op) and so hard-safety-resolved targets remain visible.
|
|
33378
|
+
*/
|
|
33379
|
+
function expandCleanTargets(absolutePatterns) {
|
|
33380
|
+
const found = /* @__PURE__ */ new Set();
|
|
33381
|
+
for (const pattern of absolutePatterns) {
|
|
33382
|
+
const matches = Ze.sync(pattern, {
|
|
33383
|
+
absolute: true,
|
|
33384
|
+
dot: true,
|
|
33385
|
+
nodir: false
|
|
33386
|
+
});
|
|
33387
|
+
if (matches.length === 0) {
|
|
33388
|
+
found.add(PATH.resolve(pattern));
|
|
33389
|
+
continue;
|
|
33390
|
+
}
|
|
33391
|
+
for (const match of matches) found.add(PATH.resolve(match));
|
|
33392
|
+
}
|
|
33393
|
+
return [...found];
|
|
33394
|
+
}
|
|
33395
|
+
function matchesCleanExclude(packageDir, absPath, exclude) {
|
|
33396
|
+
const rel = packageRelative(packageDir, absPath);
|
|
33397
|
+
if (rel === "" || rel.startsWith("..")) {
|
|
33398
|
+
const fromPkg = toPosix(PATH.relative(packageDir, absPath));
|
|
33399
|
+
return exclude.some((pattern) => isMatch(fromPkg, pattern, { dot: true }));
|
|
33400
|
+
}
|
|
33401
|
+
return exclude.some((pattern) => {
|
|
33402
|
+
if (isMatch(rel, pattern, { dot: true })) return true;
|
|
33403
|
+
const asDir = pattern.endsWith("/**") ? pattern : `${pattern.replace(/\/$/, "")}/**`;
|
|
33404
|
+
return isMatch(rel, asDir, { dot: true });
|
|
33405
|
+
});
|
|
33406
|
+
}
|
|
33407
|
+
function filterByExclude(packageDir, paths, exclude) {
|
|
33408
|
+
return paths.filter((absPath) => !matchesCleanExclude(packageDir, absPath, exclude));
|
|
33409
|
+
}
|
|
33410
|
+
function filterInsideRoot(rootDir, paths) {
|
|
33411
|
+
return paths.filter((absPath) => isStrictlyInsideRoot(rootDir, absPath));
|
|
33412
|
+
}
|
|
33413
|
+
function issueLevel(level) {
|
|
33414
|
+
return level === "warn" ? "warn" : "error";
|
|
33415
|
+
}
|
|
33416
|
+
function applyGitignoredOnly(params) {
|
|
33417
|
+
const { existing, gitignore, issues, packageDir, rootDir, ruleLevel, targets } = params;
|
|
33418
|
+
if (existing.length === 0) return;
|
|
33419
|
+
if (!gitignore.isGitRepo(rootDir)) {
|
|
33420
|
+
issues.push({
|
|
33421
|
+
level: issueLevel(ruleLevel),
|
|
33422
|
+
message: "clean.gitignored-only is enabled but the package is not inside a git work tree",
|
|
33423
|
+
rule: "clean.gitignored-only"
|
|
33424
|
+
});
|
|
33425
|
+
if (ruleLevel === "warn") for (const absPath of existing) targets.add(absPath);
|
|
33426
|
+
return;
|
|
33427
|
+
}
|
|
33428
|
+
const { ignored, notIgnored } = filterGitIgnoredPaths(rootDir, existing, gitignore);
|
|
33429
|
+
for (const absPath of ignored) targets.add(absPath);
|
|
33430
|
+
for (const absPath of notIgnored) {
|
|
33431
|
+
const rel = packageRelative(packageDir, absPath);
|
|
33432
|
+
issues.push({
|
|
33433
|
+
level: issueLevel(ruleLevel),
|
|
33434
|
+
message: `Refusing to clean non-gitignored path "${rel}" (clean.gitignored-only)`,
|
|
33435
|
+
rule: "clean.gitignored-only"
|
|
33436
|
+
});
|
|
33437
|
+
}
|
|
33438
|
+
}
|
|
33439
|
+
function applyGitignoredAll(params) {
|
|
33440
|
+
const { gitignore, issues, packageDir, rootDir, ruleLevel, targets } = params;
|
|
33441
|
+
if (gitignore.isGitRepo(rootDir)) {
|
|
33442
|
+
for (const absPath of gitignore.listIgnoredUnder(rootDir, packageDir)) targets.add(absPath);
|
|
33443
|
+
return;
|
|
33444
|
+
}
|
|
33445
|
+
issues.push({
|
|
33446
|
+
level: issueLevel(ruleLevel),
|
|
33447
|
+
message: "clean.gitignored-all is enabled but the package is not inside a git work tree",
|
|
33448
|
+
rule: "clean.gitignored-all"
|
|
33449
|
+
});
|
|
33450
|
+
}
|
|
33451
|
+
/**
|
|
33452
|
+
* Build the set of absolute paths `xy clean` will delete for one package.
|
|
33453
|
+
*
|
|
33454
|
+
* Pipeline:
|
|
33455
|
+
* 1. Hard safety on all configured patterns (throws on escape)
|
|
33456
|
+
* 2. Expand builtins + include (always-clean; bypass gitignored-only)
|
|
33457
|
+
* 3. Expand config patterns; enforce gitignored-only when enabled
|
|
33458
|
+
* 4. Optionally add all gitignored paths under the package
|
|
33459
|
+
* 5. Apply exclude + re-check inside-root
|
|
33460
|
+
*/
|
|
33461
|
+
function buildCleanPlan(options) {
|
|
33462
|
+
const { config, extraPatterns = [], gitignore = gitCleanGitignoreBackend, packageDir, rootDir } = options;
|
|
33463
|
+
const rules = resolveCleanRules(config);
|
|
33464
|
+
const issues = [];
|
|
33465
|
+
const exclude = resolveCleanExclude(config);
|
|
33466
|
+
const configuredPatterns = [...resolveCleanPatterns(config), ...extraPatterns];
|
|
33467
|
+
const safeBuiltin = resolveSafeCleanPatterns([...BUILTIN_CLEAN_PATTERNS], packageDir, rootDir);
|
|
33468
|
+
const safeInclude = resolveSafeCleanPatterns(resolveCleanInclude(config), packageDir, rootDir);
|
|
33469
|
+
const safePatterns = resolveSafeCleanPatterns(configuredPatterns, packageDir, rootDir);
|
|
33470
|
+
const targets = /* @__PURE__ */ new Set([...expandCleanTargets(safeBuiltin), ...expandCleanTargets(safeInclude)]);
|
|
33471
|
+
const patternCandidates = expandCleanTargets(safePatterns).filter((absPath) => !targets.has(absPath));
|
|
33472
|
+
if (isCleanRuleEnabled(rules.gitignoredOnly) && patternCandidates.length > 0) {
|
|
33473
|
+
const existing = patternCandidates.filter((absPath) => fs.existsSync(absPath));
|
|
33474
|
+
for (const absPath of patternCandidates) if (!fs.existsSync(absPath)) targets.add(absPath);
|
|
33475
|
+
applyGitignoredOnly({
|
|
33476
|
+
existing,
|
|
33477
|
+
gitignore,
|
|
33478
|
+
issues,
|
|
33479
|
+
packageDir,
|
|
33480
|
+
rootDir,
|
|
33481
|
+
ruleLevel: rules.gitignoredOnly,
|
|
33482
|
+
targets
|
|
33483
|
+
});
|
|
33484
|
+
} else for (const absPath of patternCandidates) targets.add(absPath);
|
|
33485
|
+
if (isCleanRuleEnabled(rules.gitignoredAll)) applyGitignoredAll({
|
|
33486
|
+
gitignore,
|
|
33487
|
+
issues,
|
|
33488
|
+
packageDir,
|
|
33489
|
+
rootDir,
|
|
33490
|
+
ruleLevel: rules.gitignoredAll,
|
|
33491
|
+
targets
|
|
33492
|
+
});
|
|
33493
|
+
return {
|
|
33494
|
+
deletePaths: filterInsideRoot(rootDir, filterByExclude(packageDir, [...targets], exclude)).toSorted((a, b) => a.localeCompare(b)),
|
|
33495
|
+
issues,
|
|
33496
|
+
rules
|
|
33497
|
+
};
|
|
33498
|
+
}
|
|
33499
|
+
function cleanPlanExitCode(plan) {
|
|
33500
|
+
return plan.issues.some((issue) => issue.level === "error") ? 1 : 0;
|
|
33501
|
+
}
|
|
33502
|
+
//#endregion
|
|
33107
33503
|
//#region src/actions/package/clean-outputs.ts
|
|
33108
|
-
|
|
33504
|
+
async function loadCleanConfig(pkg) {
|
|
33505
|
+
return await loadWorkspaceCommandConfig(pkg, "clean");
|
|
33506
|
+
}
|
|
33507
|
+
function mergeExtraPatterns(config, extraPatterns) {
|
|
33508
|
+
if (extraPatterns === void 0 || extraPatterns.length === 0) return config;
|
|
33509
|
+
return {
|
|
33510
|
+
...config,
|
|
33511
|
+
patterns: [...config.patterns ?? [], ...extraPatterns]
|
|
33512
|
+
};
|
|
33513
|
+
}
|
|
33514
|
+
function deletePaths(paths) {
|
|
33515
|
+
const ordered = [...paths].toSorted((a, b) => b.length - a.length);
|
|
33516
|
+
for (const target of ordered) deleteGlob(target);
|
|
33517
|
+
}
|
|
33518
|
+
const packageCleanOutputs = async (options = {}) => {
|
|
33109
33519
|
const pkg = options.pkg ?? INIT_CWD();
|
|
33110
33520
|
const pkgName = options.pkgName ?? packageName();
|
|
33111
|
-
const
|
|
33112
|
-
|
|
33113
|
-
|
|
33114
|
-
|
|
33115
|
-
|
|
33116
|
-
|
|
33117
|
-
|
|
33118
|
-
|
|
33521
|
+
const rootDir = options.rootDir ?? findWorkspaceRoot(pkg);
|
|
33522
|
+
const log = isJsonMode() ? console.error : console.log;
|
|
33523
|
+
log(chalk.green(`Cleaning Outputs [${pkgName}]`));
|
|
33524
|
+
const baseConfig = options.skipConfigLoad ? { patterns: options.extraPatterns } : await loadCleanConfig(pkg);
|
|
33525
|
+
const plan = buildCleanPlan({
|
|
33526
|
+
config: options.skipConfigLoad ? baseConfig : mergeExtraPatterns(baseConfig, options.extraPatterns),
|
|
33527
|
+
gitignore: options.gitignore,
|
|
33528
|
+
packageDir: pkg,
|
|
33529
|
+
rootDir
|
|
33530
|
+
});
|
|
33531
|
+
for (const issue of plan.issues) log((issue.level === "error" ? chalk.red : chalk.yellow)(` ${issue.level === "error" ? "✗" : "⚠"} [${issue.rule}] ${issue.message}`));
|
|
33532
|
+
deletePaths(plan.deletePaths);
|
|
33533
|
+
if (plan.deletePaths.length > 0 && !isJsonMode()) for (const deleted of plan.deletePaths) {
|
|
33534
|
+
const relative = PATH.relative(pkg, deleted);
|
|
33535
|
+
log(chalk.gray(` removed ${relative.length > 0 ? relative : deleted}`));
|
|
33536
|
+
}
|
|
33537
|
+
return cleanPlanExitCode(plan);
|
|
33119
33538
|
};
|
|
33120
33539
|
//#endregion
|
|
33121
33540
|
//#region src/actions/package/clean-typescript.ts
|
|
33541
|
+
/** Cleans TypeScript build info and local lint caches for a package. */
|
|
33122
33542
|
const packageCleanTypescript = (options = {}) => {
|
|
33123
33543
|
const pkg = options.pkg ?? INIT_CWD();
|
|
33124
33544
|
const pkgName = options.pkgName ?? packageName();
|
|
@@ -33133,8 +33553,8 @@ const packageCleanTypescript = (options = {}) => {
|
|
|
33133
33553
|
};
|
|
33134
33554
|
//#endregion
|
|
33135
33555
|
//#region src/actions/package/clean.ts
|
|
33136
|
-
const packageClean = (options = {}) => {
|
|
33137
|
-
return
|
|
33556
|
+
const packageClean = async (options = {}) => {
|
|
33557
|
+
return await packageCleanOutputs(options) + packageCleanTypescript(options);
|
|
33138
33558
|
};
|
|
33139
33559
|
//#endregion
|
|
33140
33560
|
//#region src/actions/package/compile/inputs.ts
|
|
@@ -36603,7 +37023,7 @@ function migrateFieldToExports(pkg, field, exportKey, shouldFix) {
|
|
|
36603
37023
|
const exports = pkg.exports;
|
|
36604
37024
|
if (exports && typeof exports === "object") {
|
|
36605
37025
|
const dot = exports["."];
|
|
36606
|
-
if (
|
|
37026
|
+
if (typeof dot === "object" && dot != null && !Object.hasOwn(dot, exportKey)) {
|
|
36607
37027
|
dot[exportKey] = exportValue;
|
|
36608
37028
|
console.warn(chalk.yellow(`Publint [custom]: migrated "${field}" to "exports['.'].${exportKey}" (${fieldValue})`));
|
|
36609
37029
|
}
|
|
@@ -36971,7 +37391,7 @@ function fixVersionConsistency(cwd, rootPkg, writeRootPackageJson, workspaces) {
|
|
|
36971
37391
|
if (!pkg) continue;
|
|
36972
37392
|
const version = pkg.version;
|
|
36973
37393
|
const validVersion = version === void 0 ? null : import_semver.default.valid(version);
|
|
36974
|
-
if (version !== void 0 && version.length > 0 && validVersion
|
|
37394
|
+
if (version !== void 0 && validVersion !== null && version.length > 0 && validVersion.length > 0) versions.push(version);
|
|
36975
37395
|
}
|
|
36976
37396
|
if (versions.length === 0) return;
|
|
36977
37397
|
const highest = versions.toSorted(import_semver.default.rcompare)[0];
|
|
@@ -37540,9 +37960,10 @@ async function cleanBuiltInWorkspaces(rootDir, workspaces, jobs) {
|
|
|
37540
37960
|
index,
|
|
37541
37961
|
workspace
|
|
37542
37962
|
})), Math.max(1, jobs), async ({ index, workspace }) => {
|
|
37543
|
-
results[index] = packageClean({
|
|
37963
|
+
results[index] = await packageClean({
|
|
37544
37964
|
pkg: PATH.resolve(rootDir, workspace.location),
|
|
37545
|
-
pkgName: workspace.name
|
|
37965
|
+
pkgName: workspace.name,
|
|
37966
|
+
rootDir
|
|
37546
37967
|
});
|
|
37547
37968
|
});
|
|
37548
37969
|
return results.reduce((total, result) => total + result, 0);
|
|
@@ -37795,11 +38216,11 @@ function handleExportDeclaration(node, declarations, reExportsFromRelative, reEx
|
|
|
37795
38216
|
const isRelative = moduleSpec?.startsWith(".") ?? false;
|
|
37796
38217
|
const deprecated = hasDeprecatedTag(node.getSourceFile(), node) ? true : void 0;
|
|
37797
38218
|
if (node.exportClause && ts.isNamedExports(node.exportClause)) {
|
|
37798
|
-
if (moduleSpec != null && moduleSpec.length > 0
|
|
38219
|
+
if (isRelative && moduleSpec != null && moduleSpec.length > 0) handleNamedExportClauseWithModule(node.exportClause, moduleSpec, reExportsFromRelative, deprecated, node.getSourceFile());
|
|
37799
38220
|
else if (moduleSpec == null || moduleSpec.length === 0) handleNamedExportClauseLocal(node.exportClause, declarations, deprecated);
|
|
37800
38221
|
return;
|
|
37801
38222
|
}
|
|
37802
|
-
if (!node.exportClause && moduleSpec != null && moduleSpec.length > 0
|
|
38223
|
+
if (isRelative && !node.exportClause && moduleSpec != null && moduleSpec.length > 0) reExportAllFromRelative.add(moduleSpec);
|
|
37803
38224
|
}
|
|
37804
38225
|
function visitTopLevel(node, ctx) {
|
|
37805
38226
|
const named = tryNamedDeclaration(node);
|
|
@@ -38424,7 +38845,7 @@ function resolveFixLocations(findings, analyses) {
|
|
|
38424
38845
|
}
|
|
38425
38846
|
function isNodeMatchingSymbol(node, symbol) {
|
|
38426
38847
|
if (ts.isIdentifier(node) && node.text === symbol) return true;
|
|
38427
|
-
if (
|
|
38848
|
+
if (symbol === "default" && ts.isExportAssignment(node)) return true;
|
|
38428
38849
|
return Boolean(ts.isExportSpecifier(node) && (node.name.text === symbol || node.propertyName?.text === symbol));
|
|
38429
38850
|
}
|
|
38430
38851
|
function isStatementContainingSymbol(statement, symbol) {
|
|
@@ -38801,8 +39222,7 @@ function isRuleApplicableToPackage(rule, analysis) {
|
|
|
38801
39222
|
function evaluateInternalRule(analysis, rule, shouldUseMonorepoRefs) {
|
|
38802
39223
|
const findings = [];
|
|
38803
39224
|
for (const symbol of analysis.symbols) {
|
|
38804
|
-
|
|
38805
|
-
if (symbol.onPublicSurface || isReferenced) continue;
|
|
39225
|
+
if (symbol[shouldUseMonorepoRefs ? "usedInMonorepo" : "isUsedInPackage"] || symbol.onPublicSurface) continue;
|
|
38806
39226
|
findings.push(makeFinding(analysis, rule.id, rule.meta.scope, symbol.file, symbol.name, symbol.line, symbol.column, void 0, symbol.deprecated));
|
|
38807
39227
|
}
|
|
38808
39228
|
return findings;
|
|
@@ -38910,7 +39330,7 @@ function evaluateRuleForAnalysis(analysis, rule, repoUsage, workspaceUsage) {
|
|
|
38910
39330
|
if (!isRuleApplicableToPackage(rule, analysis)) return [];
|
|
38911
39331
|
if (rule.meta.scope === "package") return evaluatePackageRules(analysis, rule);
|
|
38912
39332
|
if (rule.meta.scope === "repo") return evaluateRepoRules(analysis, rule, repoUsage, workspaceUsage);
|
|
38913
|
-
if (rule.meta.scope === "workspace"
|
|
39333
|
+
if (workspaceUsage !== void 0 && rule.meta.scope === "workspace") return evaluateWorkspaceRules(analysis, rule, workspaceUsage);
|
|
38914
39334
|
return [];
|
|
38915
39335
|
}
|
|
38916
39336
|
function evaluateDeadRules(analyses, rules, repoUsage, workspaceUsage) {
|
|
@@ -39578,7 +39998,7 @@ async function buildDeadAnalysisContext(targets, workspace, isVerbose, includeDe
|
|
|
39578
39998
|
analyses,
|
|
39579
39999
|
disabledWorkspaceRules,
|
|
39580
40000
|
effectiveRules: rules.map((rule) => {
|
|
39581
|
-
if (rule.requiresCodeWorkspace !== true
|
|
40001
|
+
if (hasCodeWorkspace || rule.requiresCodeWorkspace !== true) return rule;
|
|
39582
40002
|
return {
|
|
39583
40003
|
...rule,
|
|
39584
40004
|
enabled: false
|
|
@@ -39935,7 +40355,7 @@ function recordRuleOutcome(report, rule, diagnostics, fixedCount, reporter) {
|
|
|
39935
40355
|
reporter?.diagnostic?.(diagnostic);
|
|
39936
40356
|
}
|
|
39937
40357
|
if (fixedCount > 0) reporter?.fixed?.(rule, fixedCount);
|
|
39938
|
-
if (
|
|
40358
|
+
if (fixedCount === 0 && diagnostics.length === 0) reporter?.passed?.(rule);
|
|
39939
40359
|
}
|
|
39940
40360
|
async function runRuleChecks({ commandName, configKey = commandName, config, context, fix = false, reporter, rules, strict = isStrictMode() }) {
|
|
39941
40361
|
validateConfiguredRuleIds(commandName, configKey, rules, config);
|
|
@@ -40374,7 +40794,7 @@ function logLintlintDiagnostic(diagnostic) {
|
|
|
40374
40794
|
console.log(color(` ${marker} ${diagnostic.message}`));
|
|
40375
40795
|
}
|
|
40376
40796
|
function logAdditions({ additions }, isVerbose) {
|
|
40377
|
-
if (additions.length === 0
|
|
40797
|
+
if (!isVerbose || additions.length === 0) return;
|
|
40378
40798
|
console.log(chalk.gray(`\n${additions.length} local addition(s) (not in shared config):`));
|
|
40379
40799
|
for (const { rule, local } of additions) console.log(chalk.gray(` ${rule}: ${formatRule(local)}`));
|
|
40380
40800
|
}
|
|
@@ -40794,7 +41214,7 @@ function fixEnginesOnlyInNonTerminal(cwd, _pkg, workspaces) {
|
|
|
40794
41214
|
writeFileSync(pkgPath, `${JSON.stringify(pkg, null, 2)}\n`, "utf8");
|
|
40795
41215
|
console.log(chalk.green(` ✔ Fixed: removed engines from ${location}/package.json`));
|
|
40796
41216
|
}
|
|
40797
|
-
if (!isTerminalPackage(pkg) && !Boolean(pkg.engines)
|
|
41217
|
+
if (enginesTemplate && !isTerminalPackage(pkg) && !Boolean(pkg.engines)) {
|
|
40798
41218
|
pkg.engines = enginesTemplate;
|
|
40799
41219
|
writeFileSync(pkgPath, `${JSON.stringify(pkg, null, 2)}\n`, "utf8");
|
|
40800
41220
|
console.log(chalk.green(` ✔ Fixed: added engines to ${location}/package.json`));
|
|
@@ -42716,10 +43136,10 @@ function mapOutputPath(relativePath, variables) {
|
|
|
42716
43136
|
}
|
|
42717
43137
|
function isPmSpecificFile(relativePath, pm) {
|
|
42718
43138
|
if (relativePath === "pnpm-workspace.yaml" && pm !== "pnpm") return true;
|
|
42719
|
-
if (relativePath.includes("build-pnpm")
|
|
42720
|
-
if (relativePath.includes("build-npm")
|
|
42721
|
-
if (relativePath.includes("build-bun")
|
|
42722
|
-
return Boolean(relativePath.includes("build-yarn")
|
|
43139
|
+
if (pm !== "pnpm" && relativePath.includes("build-pnpm")) return true;
|
|
43140
|
+
if (pm !== "npm" && relativePath.includes("build-npm")) return true;
|
|
43141
|
+
if (pm !== "bun" && relativePath.includes("build-bun")) return true;
|
|
43142
|
+
return Boolean(pm !== "yarn" && relativePath.includes("build-yarn"));
|
|
42723
43143
|
}
|
|
42724
43144
|
function mapBuildWorkflowName(outputPath) {
|
|
42725
43145
|
return outputPath.replace(/build-(bun|npm|pnpm|yarn)\.yml/, "build.yml");
|
|
@@ -42879,6 +43299,42 @@ const retest = ({ target } = {}) => {
|
|
|
42879
43299
|
return runSteps("Re-Test", [["vitest", ["--clearCache"]], ["vitest", [target ?? "."]]]);
|
|
42880
43300
|
};
|
|
42881
43301
|
//#endregion
|
|
43302
|
+
//#region src/actions/cleanRuleCatalog.ts
|
|
43303
|
+
async function loadCommandConfig$1(commandName, pkg) {
|
|
43304
|
+
if (pkg !== void 0 && pkg.length > 0) {
|
|
43305
|
+
const workspace = getPackageManager().findWorkspace(pkg);
|
|
43306
|
+
if (workspace === void 0) throw new Error(`Workspace not found: ${pkg}`);
|
|
43307
|
+
return loadWorkspaceCommandConfig(workspace.location, commandName);
|
|
43308
|
+
}
|
|
43309
|
+
return loadWorkspaceCommandConfig(process.cwd(), commandName);
|
|
43310
|
+
}
|
|
43311
|
+
function sortRules$1(rules) {
|
|
43312
|
+
return rules.toSorted((left, right) => {
|
|
43313
|
+
const command = left.command.localeCompare(right.command);
|
|
43314
|
+
return command === 0 ? left.id.localeCompare(right.id) : command;
|
|
43315
|
+
});
|
|
43316
|
+
}
|
|
43317
|
+
async function getCleanRuleCatalog(pkg) {
|
|
43318
|
+
const resolved = resolveCleanRules(await loadCommandConfig$1("clean", pkg));
|
|
43319
|
+
const hard = CLEAN_HARD_RULES.map((rule) => ({
|
|
43320
|
+
command: RULE_COMMANDS.clean.command,
|
|
43321
|
+
defaultLevel: "error",
|
|
43322
|
+
description: `${rule.description} (always enforced)`,
|
|
43323
|
+
fixable: false,
|
|
43324
|
+
id: rule.id,
|
|
43325
|
+
level: "error"
|
|
43326
|
+
}));
|
|
43327
|
+
const configurable = CLEAN_CONFIGURABLE_RULES.map((rule) => ({
|
|
43328
|
+
command: RULE_COMMANDS.clean.command,
|
|
43329
|
+
defaultLevel: rule.defaultLevel,
|
|
43330
|
+
description: rule.description,
|
|
43331
|
+
fixable: false,
|
|
43332
|
+
id: rule.id,
|
|
43333
|
+
level: rule.id === "clean.gitignored-only" ? resolved.gitignoredOnly : resolved.gitignoredAll
|
|
43334
|
+
}));
|
|
43335
|
+
return sortRules$1([...hard, ...configurable]);
|
|
43336
|
+
}
|
|
43337
|
+
//#endregion
|
|
42882
43338
|
//#region ../../node_modules/.pnpm/ansi-regex@5.0.1/node_modules/ansi-regex/index.js
|
|
42883
43339
|
var require_ansi_regex = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
42884
43340
|
module.exports = ({ onlyFirst = false } = {}) => {
|
|
@@ -48776,8 +49232,8 @@ var require_api = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
48776
49232
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48777
49233
|
}));
|
|
48778
49234
|
//#endregion
|
|
48779
|
-
//#region
|
|
48780
|
-
var
|
|
49235
|
+
//#region src/actions/ruleCatalogRender.ts
|
|
49236
|
+
var import_src = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
48781
49237
|
var __createBinding = exports && exports.__createBinding || (Object.create ? (function(o, m, k, k2) {
|
|
48782
49238
|
if (k2 === void 0) k2 = k;
|
|
48783
49239
|
Object.defineProperty(o, k2, {
|
|
@@ -48817,7 +49273,130 @@ var require_src = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
48817
49273
|
}
|
|
48818
49274
|
});
|
|
48819
49275
|
__exportStar(require_api(), exports);
|
|
48820
|
-
}));
|
|
49276
|
+
})))();
|
|
49277
|
+
const levelColor = {
|
|
49278
|
+
error: "red",
|
|
49279
|
+
off: "gray",
|
|
49280
|
+
warn: "yellow"
|
|
49281
|
+
};
|
|
49282
|
+
function sortRules(rules) {
|
|
49283
|
+
return rules.toSorted((left, right) => {
|
|
49284
|
+
const command = left.command.localeCompare(right.command);
|
|
49285
|
+
return command === 0 ? left.id.localeCompare(right.id) : command;
|
|
49286
|
+
});
|
|
49287
|
+
}
|
|
49288
|
+
function maxWidth(header, values, max = Infinity) {
|
|
49289
|
+
return Math.min(max, Math.max(header.length, ...values.map((value) => value.length)));
|
|
49290
|
+
}
|
|
49291
|
+
function resolveTableWidth() {
|
|
49292
|
+
const columns = process.stdout.isTTY ? process.stdout.columns : void 0;
|
|
49293
|
+
return Math.max(72, Math.min(columns ?? 120, 160) - 2);
|
|
49294
|
+
}
|
|
49295
|
+
function resolveRuleTableWidths(rows, hasWeight) {
|
|
49296
|
+
const columnCount = hasWeight ? 5 : 4;
|
|
49297
|
+
const tableChromeWidth = columnCount + 1 + columnCount * 2;
|
|
49298
|
+
const level = maxWidth("Level", rows.map((row) => row.level));
|
|
49299
|
+
const fix = maxWidth("Fix", rows.map((row) => row.fix));
|
|
49300
|
+
const weight = hasWeight ? maxWidth("Weight", rows.map((row) => row.weight), 12) : void 0;
|
|
49301
|
+
let id = maxWidth("Rule", rows.map((row) => row.id), 56);
|
|
49302
|
+
const fixedWidth = () => tableChromeWidth + level + fix + id + (weight ?? 0);
|
|
49303
|
+
const minimumDescription = 28;
|
|
49304
|
+
const tableWidth = resolveTableWidth();
|
|
49305
|
+
if (tableWidth - fixedWidth() < minimumDescription) id = Math.max(24, id - (minimumDescription - (tableWidth - fixedWidth())));
|
|
49306
|
+
const availableDescription = Math.max(20, tableWidth - fixedWidth());
|
|
49307
|
+
const naturalDescription = maxWidth("Description", rows.map((row) => row.description), 72);
|
|
49308
|
+
return {
|
|
49309
|
+
description: Math.min(naturalDescription, availableDescription),
|
|
49310
|
+
fix,
|
|
49311
|
+
id,
|
|
49312
|
+
level,
|
|
49313
|
+
...weight !== void 0 && { weight }
|
|
49314
|
+
};
|
|
49315
|
+
}
|
|
49316
|
+
function ruleTableConfig(widths, hasWeight) {
|
|
49317
|
+
return {
|
|
49318
|
+
border: (0, import_src.getBorderCharacters)("norc"),
|
|
49319
|
+
columnDefault: {
|
|
49320
|
+
paddingLeft: 1,
|
|
49321
|
+
paddingRight: 1,
|
|
49322
|
+
wrapWord: true
|
|
49323
|
+
},
|
|
49324
|
+
columns: {
|
|
49325
|
+
0: { width: widths.level },
|
|
49326
|
+
1: { width: widths.id },
|
|
49327
|
+
2: {
|
|
49328
|
+
alignment: "center",
|
|
49329
|
+
width: widths.fix
|
|
49330
|
+
},
|
|
49331
|
+
...hasWeight ? {
|
|
49332
|
+
3: {
|
|
49333
|
+
alignment: "right",
|
|
49334
|
+
width: widths.weight
|
|
49335
|
+
},
|
|
49336
|
+
4: { width: widths.description }
|
|
49337
|
+
} : { 3: { width: widths.description } }
|
|
49338
|
+
},
|
|
49339
|
+
drawHorizontalLine: (index, size) => [
|
|
49340
|
+
0,
|
|
49341
|
+
1,
|
|
49342
|
+
size
|
|
49343
|
+
].includes(index)
|
|
49344
|
+
};
|
|
49345
|
+
}
|
|
49346
|
+
function formatRuleTable(rules) {
|
|
49347
|
+
const rows = rules.map((rule) => ({
|
|
49348
|
+
description: rule.description ?? "",
|
|
49349
|
+
fix: rule.fixable ? "yes" : "no",
|
|
49350
|
+
id: rule.id,
|
|
49351
|
+
level: rule.defaultLevel === rule.level ? rule.defaultLevel : `${rule.defaultLevel} (${rule.level})`,
|
|
49352
|
+
resolvedLevel: rule.level,
|
|
49353
|
+
weight: rule.weight === void 0 ? "" : String(rule.weight)
|
|
49354
|
+
}));
|
|
49355
|
+
const hasWeight = rows.some((row) => row.weight.length > 0);
|
|
49356
|
+
const widths = resolveRuleTableWidths(rows, hasWeight);
|
|
49357
|
+
return (0, import_src.table)([[
|
|
49358
|
+
chalk.gray.bold("Level"),
|
|
49359
|
+
chalk.gray.bold("Rule"),
|
|
49360
|
+
chalk.gray.bold("Fix"),
|
|
49361
|
+
...hasWeight ? [chalk.gray.bold("Weight")] : [],
|
|
49362
|
+
chalk.gray.bold("Description")
|
|
49363
|
+
], ...rows.map((row) => [
|
|
49364
|
+
chalk[levelColor[row.resolvedLevel]](row.level),
|
|
49365
|
+
chalk.cyan(row.id),
|
|
49366
|
+
chalk.gray(row.fix),
|
|
49367
|
+
...hasWeight ? [chalk.gray(row.weight)] : [],
|
|
49368
|
+
chalk.gray(row.description)
|
|
49369
|
+
])], ruleTableConfig(widths, hasWeight)).trimEnd().split("\n").map((line) => ` ${line}`).join("\n");
|
|
49370
|
+
}
|
|
49371
|
+
function renderRuleCatalog(rules, title = "Rules") {
|
|
49372
|
+
console.log(chalk.bold(title));
|
|
49373
|
+
let currentCommand;
|
|
49374
|
+
let currentRules = [];
|
|
49375
|
+
const sortedRules = sortRules([...rules]);
|
|
49376
|
+
for (const rule of sortedRules) {
|
|
49377
|
+
if (rule.command !== currentCommand) {
|
|
49378
|
+
if (currentRules.length > 0) console.log(formatRuleTable(currentRules));
|
|
49379
|
+
currentCommand = rule.command;
|
|
49380
|
+
currentRules = [];
|
|
49381
|
+
console.log();
|
|
49382
|
+
console.log(chalk.green(currentCommand));
|
|
49383
|
+
}
|
|
49384
|
+
currentRules.push(rule);
|
|
49385
|
+
}
|
|
49386
|
+
if (currentRules.length > 0) console.log(formatRuleTable(currentRules));
|
|
49387
|
+
}
|
|
49388
|
+
function ruleCatalogResult(rules, title) {
|
|
49389
|
+
const sorted = sortRules(rules);
|
|
49390
|
+
if (!isJsonMode()) renderRuleCatalog(sorted, title);
|
|
49391
|
+
return {
|
|
49392
|
+
envelope: {
|
|
49393
|
+
data: sorted,
|
|
49394
|
+
errorCount: 0,
|
|
49395
|
+
warningCount: 0
|
|
49396
|
+
},
|
|
49397
|
+
exitCode: 0
|
|
49398
|
+
};
|
|
49399
|
+
}
|
|
48821
49400
|
//#endregion
|
|
48822
49401
|
//#region src/actions/skills/passthrough.ts
|
|
48823
49402
|
const ANSI_PREFIX = String.raw`\x1B\[[\d;]*m`;
|
|
@@ -49240,7 +49819,7 @@ const installMissingSkill = async (skillName) => {
|
|
|
49240
49819
|
]);
|
|
49241
49820
|
};
|
|
49242
49821
|
const missingSkillReason = (profile, skillName) => {
|
|
49243
|
-
if (
|
|
49822
|
+
if (skillName === "xy-toolchain" && profile.isUsingToolchain) return "repo uses @ariestools/toolchain";
|
|
49244
49823
|
return "required for repo profile";
|
|
49245
49824
|
};
|
|
49246
49825
|
const checkRequiredSkills = (required, installed, latestVersions, profile, isOffline) => {
|
|
@@ -49409,12 +49988,6 @@ const skillsLint = async (options = {}) => {
|
|
|
49409
49988
|
};
|
|
49410
49989
|
//#endregion
|
|
49411
49990
|
//#region src/actions/ruleCatalog.ts
|
|
49412
|
-
var import_src = require_src();
|
|
49413
|
-
const levelColor = {
|
|
49414
|
-
error: "red",
|
|
49415
|
-
off: "gray",
|
|
49416
|
-
warn: "yellow"
|
|
49417
|
-
};
|
|
49418
49991
|
const REPO_LINT_RULES = [
|
|
49419
49992
|
[
|
|
49420
49993
|
"repo.root-private",
|
|
@@ -49538,12 +50111,6 @@ async function loadCommandConfig(commandName, pkg) {
|
|
|
49538
50111
|
}
|
|
49539
50112
|
return loadWorkspaceCommandConfig(process.cwd(), commandName);
|
|
49540
50113
|
}
|
|
49541
|
-
function sortRules(rules) {
|
|
49542
|
-
return rules.toSorted((left, right) => {
|
|
49543
|
-
const command = left.command.localeCompare(right.command);
|
|
49544
|
-
return command === 0 ? left.id.localeCompare(right.id) : command;
|
|
49545
|
-
});
|
|
49546
|
-
}
|
|
49547
50114
|
function staticCatalog(command, configKey, definitions, config) {
|
|
49548
50115
|
const ruleSettings = config?.rules ?? {};
|
|
49549
50116
|
const known = new Set(definitions.flatMap((rule) => [rule.id, ...rule.aliases ?? []]));
|
|
@@ -49734,6 +50301,7 @@ function getCycleRuleCatalog(depth = 25) {
|
|
|
49734
50301
|
async function loadDirectRuleCatalog() {
|
|
49735
50302
|
return sortRules([...(await Promise.all([
|
|
49736
50303
|
getApiExposureRuleCatalog(),
|
|
50304
|
+
getCleanRuleCatalog(),
|
|
49737
50305
|
getDeadRuleCatalog(),
|
|
49738
50306
|
getDeplintRuleCatalog(),
|
|
49739
50307
|
getGitlintRuleCatalog(),
|
|
@@ -49767,118 +50335,6 @@ async function getFixRuleCatalog() {
|
|
|
49767
50335
|
async function getMasterRuleCatalog() {
|
|
49768
50336
|
return sortRules(await loadDirectRuleCatalog());
|
|
49769
50337
|
}
|
|
49770
|
-
function maxWidth(header, values, max = Infinity) {
|
|
49771
|
-
return Math.min(max, Math.max(header.length, ...values.map((value) => value.length)));
|
|
49772
|
-
}
|
|
49773
|
-
function resolveTableWidth() {
|
|
49774
|
-
const columns = process.stdout.isTTY ? process.stdout.columns : void 0;
|
|
49775
|
-
return Math.max(72, Math.min(columns ?? 120, 160) - 2);
|
|
49776
|
-
}
|
|
49777
|
-
function resolveRuleTableWidths(rows, hasWeight) {
|
|
49778
|
-
const columnCount = hasWeight ? 5 : 4;
|
|
49779
|
-
const tableChromeWidth = columnCount + 1 + columnCount * 2;
|
|
49780
|
-
const level = maxWidth("Level", rows.map((row) => row.level));
|
|
49781
|
-
const fix = maxWidth("Fix", rows.map((row) => row.fix));
|
|
49782
|
-
const weight = hasWeight ? maxWidth("Weight", rows.map((row) => row.weight), 12) : void 0;
|
|
49783
|
-
let id = maxWidth("Rule", rows.map((row) => row.id), 56);
|
|
49784
|
-
const fixedWidth = () => tableChromeWidth + level + fix + id + (weight ?? 0);
|
|
49785
|
-
const minimumDescription = 28;
|
|
49786
|
-
const tableWidth = resolveTableWidth();
|
|
49787
|
-
if (tableWidth - fixedWidth() < minimumDescription) id = Math.max(24, id - (minimumDescription - (tableWidth - fixedWidth())));
|
|
49788
|
-
const availableDescription = Math.max(20, tableWidth - fixedWidth());
|
|
49789
|
-
const naturalDescription = maxWidth("Description", rows.map((row) => row.description), 72);
|
|
49790
|
-
return {
|
|
49791
|
-
description: Math.min(naturalDescription, availableDescription),
|
|
49792
|
-
fix,
|
|
49793
|
-
id,
|
|
49794
|
-
level,
|
|
49795
|
-
...weight !== void 0 && { weight }
|
|
49796
|
-
};
|
|
49797
|
-
}
|
|
49798
|
-
function ruleTableConfig(widths, hasWeight) {
|
|
49799
|
-
return {
|
|
49800
|
-
border: (0, import_src.getBorderCharacters)("norc"),
|
|
49801
|
-
columnDefault: {
|
|
49802
|
-
paddingLeft: 1,
|
|
49803
|
-
paddingRight: 1,
|
|
49804
|
-
wrapWord: true
|
|
49805
|
-
},
|
|
49806
|
-
columns: {
|
|
49807
|
-
0: { width: widths.level },
|
|
49808
|
-
1: { width: widths.id },
|
|
49809
|
-
2: {
|
|
49810
|
-
alignment: "center",
|
|
49811
|
-
width: widths.fix
|
|
49812
|
-
},
|
|
49813
|
-
...hasWeight ? {
|
|
49814
|
-
3: {
|
|
49815
|
-
alignment: "right",
|
|
49816
|
-
width: widths.weight
|
|
49817
|
-
},
|
|
49818
|
-
4: { width: widths.description }
|
|
49819
|
-
} : { 3: { width: widths.description } }
|
|
49820
|
-
},
|
|
49821
|
-
drawHorizontalLine: (index, size) => [
|
|
49822
|
-
0,
|
|
49823
|
-
1,
|
|
49824
|
-
size
|
|
49825
|
-
].includes(index)
|
|
49826
|
-
};
|
|
49827
|
-
}
|
|
49828
|
-
function formatRuleTable(rules) {
|
|
49829
|
-
const rows = rules.map((rule) => ({
|
|
49830
|
-
description: rule.description ?? "",
|
|
49831
|
-
fix: rule.fixable ? "yes" : "no",
|
|
49832
|
-
id: rule.id,
|
|
49833
|
-
level: rule.defaultLevel === rule.level ? rule.defaultLevel : `${rule.defaultLevel} (${rule.level})`,
|
|
49834
|
-
resolvedLevel: rule.level,
|
|
49835
|
-
weight: rule.weight === void 0 ? "" : String(rule.weight)
|
|
49836
|
-
}));
|
|
49837
|
-
const hasWeight = rows.some((row) => row.weight.length > 0);
|
|
49838
|
-
const widths = resolveRuleTableWidths(rows, hasWeight);
|
|
49839
|
-
return (0, import_src.table)([[
|
|
49840
|
-
chalk.gray.bold("Level"),
|
|
49841
|
-
chalk.gray.bold("Rule"),
|
|
49842
|
-
chalk.gray.bold("Fix"),
|
|
49843
|
-
...hasWeight ? [chalk.gray.bold("Weight")] : [],
|
|
49844
|
-
chalk.gray.bold("Description")
|
|
49845
|
-
], ...rows.map((row) => [
|
|
49846
|
-
chalk[levelColor[row.resolvedLevel]](row.level),
|
|
49847
|
-
chalk.cyan(row.id),
|
|
49848
|
-
chalk.gray(row.fix),
|
|
49849
|
-
...hasWeight ? [chalk.gray(row.weight)] : [],
|
|
49850
|
-
chalk.gray(row.description)
|
|
49851
|
-
])], ruleTableConfig(widths, hasWeight)).trimEnd().split("\n").map((line) => ` ${line}`).join("\n");
|
|
49852
|
-
}
|
|
49853
|
-
function renderRuleCatalog(rules, title = "Rules") {
|
|
49854
|
-
console.log(chalk.bold(title));
|
|
49855
|
-
let currentCommand;
|
|
49856
|
-
let currentRules = [];
|
|
49857
|
-
const sortedRules = sortRules([...rules]);
|
|
49858
|
-
for (const rule of sortedRules) {
|
|
49859
|
-
if (rule.command !== currentCommand) {
|
|
49860
|
-
if (currentRules.length > 0) console.log(formatRuleTable(currentRules));
|
|
49861
|
-
currentCommand = rule.command;
|
|
49862
|
-
currentRules = [];
|
|
49863
|
-
console.log();
|
|
49864
|
-
console.log(chalk.green(currentCommand));
|
|
49865
|
-
}
|
|
49866
|
-
currentRules.push(rule);
|
|
49867
|
-
}
|
|
49868
|
-
if (currentRules.length > 0) console.log(formatRuleTable(currentRules));
|
|
49869
|
-
}
|
|
49870
|
-
function ruleCatalogResult(rules, title) {
|
|
49871
|
-
const sorted = sortRules(rules);
|
|
49872
|
-
if (!isJsonMode()) renderRuleCatalog(sorted, title);
|
|
49873
|
-
return {
|
|
49874
|
-
envelope: {
|
|
49875
|
-
data: sorted,
|
|
49876
|
-
errorCount: 0,
|
|
49877
|
-
warningCount: 0
|
|
49878
|
-
},
|
|
49879
|
-
exitCode: 0
|
|
49880
|
-
};
|
|
49881
|
-
}
|
|
49882
50338
|
//#endregion
|
|
49883
50339
|
//#region src/actions/secure.ts
|
|
49884
50340
|
const secure = async ({ jobs = 16, pkg, verbose = false } = {}) => {
|