skuba 14.0.0-replace-global-vars-20251117052457 → 14.0.0-rfc-upgrade-on-test-20251217012156
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/config/eslint.js +1 -1
- package/config/jest.js +1 -0
- package/config/prettier.d.ts +4 -8
- package/config/prettier.js +2 -10
- package/jest/moduleNameMapper.js +64 -0
- package/jest/transform.js +62 -0
- package/jest/tsConfig.js +26 -0
- package/jest-preset.js +37 -0
- package/lib/api/jest/index.d.ts +15 -0
- package/lib/api/jest/index.js +59 -0
- package/lib/api/jest/index.js.map +7 -0
- package/lib/cli/adapter/eslint.js +45 -11
- package/lib/cli/adapter/eslint.js.map +2 -2
- package/lib/cli/adapter/prettier.js +67 -39
- package/lib/cli/adapter/prettier.js.map +2 -2
- package/lib/cli/build/args.js +42 -8
- package/lib/cli/build/args.js.map +2 -2
- package/lib/cli/build/assets.js +60 -28
- package/lib/cli/build/assets.js.map +2 -2
- package/lib/cli/build/esbuild.js +45 -21
- package/lib/cli/build/esbuild.js.map +2 -2
- package/lib/cli/build/index.js +45 -21
- package/lib/cli/build/index.js.map +1 -1
- package/lib/cli/build/tsc.js +59 -22
- package/lib/cli/build/tsc.js.map +2 -2
- package/lib/cli/buildPackage/index.js +32 -8
- package/lib/cli/buildPackage/index.js.map +1 -1
- package/lib/cli/configure/analyseConfiguration.js +50 -16
- package/lib/cli/configure/analyseConfiguration.js.map +2 -2
- package/lib/cli/configure/analyseDependencies.d.ts +1 -1
- package/lib/cli/configure/analyseDependencies.js +59 -25
- package/lib/cli/configure/analyseDependencies.js.map +3 -3
- package/lib/cli/configure/analysis/diff.js +29 -5
- package/lib/cli/configure/analysis/diff.js.map +1 -1
- package/lib/cli/configure/analysis/files.js +42 -8
- package/lib/cli/configure/analysis/files.js.map +2 -2
- package/lib/cli/configure/analysis/git.js +46 -12
- package/lib/cli/configure/analysis/git.js.map +2 -2
- package/lib/cli/configure/analysis/package.d.ts +3 -2
- package/lib/cli/configure/analysis/package.js +45 -10
- package/lib/cli/configure/analysis/package.js.map +3 -3
- package/lib/cli/configure/analysis/project.js +50 -18
- package/lib/cli/configure/analysis/project.js.map +2 -2
- package/lib/cli/configure/dependencies/index.js +35 -7
- package/lib/cli/configure/dependencies/index.js.map +1 -1
- package/lib/cli/configure/dependencies/seekDatadogCustomMetrics.js +28 -4
- package/lib/cli/configure/dependencies/seekDatadogCustomMetrics.js.map +1 -1
- package/lib/cli/configure/dependencies/seekKoala.js +28 -4
- package/lib/cli/configure/dependencies/seekKoala.js.map +1 -1
- package/lib/cli/configure/dependencies/skuba.js +28 -4
- package/lib/cli/configure/dependencies/skuba.js.map +1 -1
- package/lib/cli/configure/dependencies/skubaDeps.js +26 -2
- package/lib/cli/configure/dependencies/skubaDeps.js.map +1 -1
- package/lib/cli/configure/dependencies/skubaDive.js +29 -4
- package/lib/cli/configure/dependencies/skubaDive.js.map +1 -1
- package/lib/cli/configure/ensureTemplateCompletion.d.ts +1 -1
- package/lib/cli/configure/ensureTemplateCompletion.js +61 -33
- package/lib/cli/configure/ensureTemplateCompletion.js.map +3 -3
- package/lib/cli/configure/getEntryPoint.d.ts +1 -1
- package/lib/cli/configure/getEntryPoint.js +48 -14
- package/lib/cli/configure/getEntryPoint.js.map +3 -3
- package/lib/cli/configure/getProjectType.d.ts +1 -1
- package/lib/cli/configure/getProjectType.js +35 -14
- package/lib/cli/configure/getProjectType.js.map +2 -2
- package/lib/cli/configure/index.js +84 -50
- package/lib/cli/configure/index.js.map +2 -2
- package/lib/cli/configure/modules/eslint.js +34 -10
- package/lib/cli/configure/modules/eslint.js.map +1 -1
- package/lib/cli/configure/modules/ignore.js +32 -8
- package/lib/cli/configure/modules/ignore.js.map +1 -1
- package/lib/cli/configure/modules/index.js +44 -18
- package/lib/cli/configure/modules/index.js.map +2 -2
- package/lib/cli/configure/modules/jest.d.ts +2 -0
- package/lib/cli/configure/modules/jest.js +86 -0
- package/lib/cli/configure/modules/jest.js.map +7 -0
- package/lib/cli/configure/modules/nodemon.js +28 -4
- package/lib/cli/configure/modules/nodemon.js.map +1 -1
- package/lib/cli/configure/modules/package.js +34 -10
- package/lib/cli/configure/modules/package.js.map +1 -1
- package/lib/cli/configure/modules/prettier.js +35 -11
- package/lib/cli/configure/modules/prettier.js.map +1 -1
- package/lib/cli/configure/modules/renovate.js +40 -17
- package/lib/cli/configure/modules/renovate.js.map +2 -2
- package/lib/cli/configure/modules/serverless.js +26 -2
- package/lib/cli/configure/modules/serverless.js.map +1 -1
- package/lib/cli/configure/modules/tslint.js +28 -4
- package/lib/cli/configure/modules/tslint.js.map +1 -1
- package/lib/cli/configure/processing/configFile.js +39 -3
- package/lib/cli/configure/processing/configFile.js.map +1 -1
- package/lib/cli/configure/processing/deleteFiles.js +26 -2
- package/lib/cli/configure/processing/deleteFiles.js.map +1 -1
- package/lib/cli/configure/processing/javascript.js +27 -2
- package/lib/cli/configure/processing/javascript.js.map +1 -1
- package/lib/cli/configure/processing/json.js +31 -6
- package/lib/cli/configure/processing/json.js.map +1 -1
- package/lib/cli/configure/processing/loadFiles.js +26 -2
- package/lib/cli/configure/processing/loadFiles.js.map +1 -1
- package/lib/cli/configure/processing/module.js +28 -4
- package/lib/cli/configure/processing/module.js.map +1 -1
- package/lib/cli/configure/processing/package.d.ts +67 -1
- package/lib/cli/configure/processing/package.js +45 -8
- package/lib/cli/configure/processing/package.js.map +3 -3
- package/lib/cli/configure/processing/prettier.js +38 -4
- package/lib/cli/configure/processing/prettier.js.map +2 -2
- package/lib/cli/configure/processing/record.js +41 -5
- package/lib/cli/configure/processing/record.js.map +2 -2
- package/lib/cli/configure/processing/typescript.js +63 -26
- package/lib/cli/configure/processing/typescript.js.map +2 -2
- package/lib/cli/configure/types.d.ts +4 -15
- package/lib/cli/configure/types.js +16 -0
- package/lib/cli/configure/types.js.map +3 -3
- package/lib/cli/format/index.js +44 -20
- package/lib/cli/format/index.js.map +1 -1
- package/lib/cli/help/index.js +30 -6
- package/lib/cli/help/index.js.map +1 -1
- package/lib/cli/init/getConfig.d.ts +1 -1
- package/lib/cli/init/getConfig.js +100 -74
- package/lib/cli/init/getConfig.js.map +3 -3
- package/lib/cli/init/git.js +51 -16
- package/lib/cli/init/git.js.map +2 -2
- package/lib/cli/init/index.js +98 -67
- package/lib/cli/init/index.js.map +2 -2
- package/lib/cli/init/prompts.d.ts +4 -4
- package/lib/cli/init/prompts.js +48 -27
- package/lib/cli/init/prompts.js.map +2 -2
- package/lib/cli/init/types.js +41 -7
- package/lib/cli/init/types.js.map +1 -1
- package/lib/cli/init/validation.js +30 -2
- package/lib/cli/init/validation.js.map +1 -1
- package/lib/cli/init/writePackageJson.js +42 -8
- package/lib/cli/init/writePackageJson.js.map +2 -2
- package/lib/cli/lint/annotate/buildkite/eslint.js +37 -3
- package/lib/cli/lint/annotate/buildkite/eslint.js.map +1 -1
- package/lib/cli/lint/annotate/buildkite/index.js +45 -11
- package/lib/cli/lint/annotate/buildkite/index.js.map +1 -1
- package/lib/cli/lint/annotate/buildkite/internal.js +37 -3
- package/lib/cli/lint/annotate/buildkite/internal.js.map +1 -1
- package/lib/cli/lint/annotate/buildkite/prettier.js +37 -3
- package/lib/cli/lint/annotate/buildkite/prettier.js.map +1 -1
- package/lib/cli/lint/annotate/buildkite/tsc.js +37 -3
- package/lib/cli/lint/annotate/buildkite/tsc.js.map +1 -1
- package/lib/cli/lint/annotate/github/eslint.js +26 -2
- package/lib/cli/lint/annotate/github/eslint.js.map +1 -1
- package/lib/cli/lint/annotate/github/index.js +45 -11
- package/lib/cli/lint/annotate/github/index.js.map +1 -1
- package/lib/cli/lint/annotate/github/internal.js +26 -2
- package/lib/cli/lint/annotate/github/internal.js.map +1 -1
- package/lib/cli/lint/annotate/github/prettier.js +26 -2
- package/lib/cli/lint/annotate/github/prettier.js.map +1 -1
- package/lib/cli/lint/annotate/github/tsc.js +28 -4
- package/lib/cli/lint/annotate/github/tsc.js.map +2 -2
- package/lib/cli/lint/annotate/index.js +30 -6
- package/lib/cli/lint/annotate/index.js.map +1 -1
- package/lib/cli/lint/autofix.js +73 -37
- package/lib/cli/lint/autofix.js.map +1 -1
- package/lib/cli/lint/eslint.js +51 -16
- package/lib/cli/lint/eslint.js.map +3 -3
- package/lib/cli/lint/external.js +51 -19
- package/lib/cli/lint/external.js.map +2 -2
- package/lib/cli/lint/index.js +49 -25
- package/lib/cli/lint/index.js.map +1 -1
- package/lib/cli/lint/internal.js +42 -18
- package/lib/cli/lint/internal.js.map +1 -1
- package/lib/cli/lint/internalLints/detectBadCodeowners.js +33 -8
- package/lib/cli/lint/internalLints/detectBadCodeowners.js.map +1 -1
- package/lib/cli/lint/internalLints/noSkubaTemplateJs.js +45 -11
- package/lib/cli/lint/internalLints/noSkubaTemplateJs.js.map +2 -2
- package/lib/cli/lint/internalLints/patchRenovateConfig.js +55 -21
- package/lib/cli/lint/internalLints/patchRenovateConfig.js.map +2 -2
- package/lib/cli/lint/internalLints/refreshConfigFiles.js +63 -32
- package/lib/cli/lint/internalLints/refreshConfigFiles.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/index.d.ts +6 -2
- package/lib/cli/lint/internalLints/upgrade/index.js +55 -23
- package/lib/cli/lint/internalLints/upgrade/index.js.map +3 -3
- package/lib/cli/lint/internalLints/upgrade/patches/10.0.4/index.js +28 -4
- package/lib/cli/lint/internalLints/upgrade/patches/10.0.4/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/10.0.4/removeYarnIgnoreOptionalFlags.js +45 -11
- package/lib/cli/lint/internalLints/upgrade/patches/10.0.4/removeYarnIgnoreOptionalFlags.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/10.1.0/index.js +30 -6
- package/lib/cli/lint/internalLints/upgrade/patches/10.1.0/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/10.1.0/migrateNpmrcToPnpmWorkspace.js +65 -34
- package/lib/cli/lint/internalLints/upgrade/patches/10.1.0/migrateNpmrcToPnpmWorkspace.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/10.1.0/stopBundlingInCDKTests.js +46 -11
- package/lib/cli/lint/internalLints/upgrade/patches/10.1.0/stopBundlingInCDKTests.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.0.2/index.js +28 -4
- package/lib/cli/lint/internalLints/upgrade/patches/12.0.2/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/12.0.2/unhandledRejections.js +59 -23
- package/lib/cli/lint/internalLints/upgrade/patches/12.0.2/unhandledRejections.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.1.1/index.js +28 -4
- package/lib/cli/lint/internalLints/upgrade/patches/12.1.1/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/12.1.1/patchJestSnapshots.js +46 -11
- package/lib/cli/lint/internalLints/upgrade/patches/12.1.1/patchJestSnapshots.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.3.0/index.js +30 -6
- package/lib/cli/lint/internalLints/upgrade/patches/12.3.0/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/12.3.0/patchApiTokenFromEnvironment.js +46 -11
- package/lib/cli/lint/internalLints/upgrade/patches/12.3.0/patchApiTokenFromEnvironment.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.3.0/patchDockerfileSyntaxDirective.js +46 -11
- package/lib/cli/lint/internalLints/upgrade/patches/12.3.0/patchDockerfileSyntaxDirective.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.0/index.js +28 -4
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.0/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.0/patchDockerfileCIVariable.js +46 -11
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.0/patchDockerfileCIVariable.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/configureTsConfigForESM.js +67 -29
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/configureTsConfigForESM.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/index.js +34 -10
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/patchApiDockerfiles.js +45 -11
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/patchApiDockerfiles.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/rewriteSrcImports.d.ts +0 -4
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/rewriteSrcImports.js +63 -18
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/rewriteSrcImports.js.map +3 -3
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/updateLambdaConfigs.js +50 -15
- package/lib/cli/lint/internalLints/upgrade/patches/12.4.1/updateLambdaConfigs.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/index.js +40 -0
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/index.js.map +7 -0
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/patchRootTsconfig.d.ts +3 -0
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/patchRootTsconfig.js +133 -0
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/patchRootTsconfig.js.map +7 -0
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/upgradeNode.js +55 -0
- package/lib/cli/lint/internalLints/upgrade/patches/13.1.1/upgradeNode.js.map +7 -0
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/addEmptyExports.js +51 -17
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/addEmptyExports.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/index.js +34 -10
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/patchDockerfile.js +44 -10
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/patchDockerfile.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/patchServerListener.js +46 -12
- package/lib/cli/lint/internalLints/upgrade/patches/7.3.1/patchServerListener.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.0.0/index.js +28 -4
- package/lib/cli/lint/internalLints/upgrade/patches/8.0.0/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/8.0.0/patchPnpmPackageManager.js +49 -15
- package/lib/cli/lint/internalLints/upgrade/patches/8.0.0/patchPnpmPackageManager.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/collapseDuplicateMergeKeys.js +45 -11
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/collapseDuplicateMergeKeys.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/index.js +34 -10
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/moveNpmrcMounts.js +45 -11
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/moveNpmrcMounts.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerCompose.js +45 -11
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerCompose.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerImages.js +47 -13
- package/lib/cli/lint/internalLints/upgrade/patches/8.2.1/patchDockerImages.js.map +2 -2
- package/lib/cli/lint/internalLints/upgrade/patches/9.0.1/index.js +28 -4
- package/lib/cli/lint/internalLints/upgrade/patches/9.0.1/index.js.map +1 -1
- package/lib/cli/lint/internalLints/upgrade/patches/9.0.1/patchPnpmDockerImages.js +45 -11
- package/lib/cli/lint/internalLints/upgrade/patches/9.0.1/patchPnpmDockerImages.js.map +2 -2
- package/lib/cli/lint/prettier.js +50 -15
- package/lib/cli/lint/prettier.js.map +3 -3
- package/lib/cli/lint/tsc.js +28 -4
- package/lib/cli/lint/tsc.js.map +1 -1
- package/lib/cli/lint/types.js +16 -0
- package/lib/cli/lint/types.js.map +3 -3
- package/lib/cli/migrate/index.d.ts +5 -0
- package/lib/cli/migrate/index.js +79 -15
- package/lib/cli/migrate/index.js.map +2 -2
- package/lib/cli/migrate/nodeVersion/checks.d.ts +1 -14
- package/lib/cli/migrate/nodeVersion/checks.js +51 -120
- package/lib/cli/migrate/nodeVersion/checks.js.map +2 -2
- package/lib/cli/migrate/nodeVersion/index.d.ts +8 -2
- package/lib/cli/migrate/nodeVersion/index.js +239 -65
- package/lib/cli/migrate/nodeVersion/index.js.map +3 -3
- package/lib/cli/migrate/nodeVersion/upgrade.d.ts +8 -0
- package/lib/cli/migrate/nodeVersion/upgrade.js +179 -0
- package/lib/cli/migrate/nodeVersion/upgrade.js.map +7 -0
- package/lib/cli/node/index.js +57 -20
- package/lib/cli/node/index.js.map +3 -3
- package/lib/cli/release/index.js +28 -4
- package/lib/cli/release/index.js.map +1 -1
- package/lib/cli/start/index.js +50 -16
- package/lib/cli/start/index.js.map +3 -3
- package/lib/cli/test/index.js +65 -4
- package/lib/cli/test/index.js.map +2 -2
- package/lib/cli/test/reporters/github/annotations.d.ts +9 -0
- package/lib/cli/test/reporters/github/annotations.js +102 -0
- package/lib/cli/test/reporters/github/annotations.js.map +7 -0
- package/lib/cli/test/reporters/github/index.d.ts +5 -0
- package/lib/cli/test/reporters/github/index.js +74 -0
- package/lib/cli/test/reporters/github/index.js.map +7 -0
- package/lib/cli/version/index.js +30 -6
- package/lib/cli/version/index.js.map +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js +46 -6
- package/lib/index.js.map +2 -2
- package/lib/skuba.js +45 -26
- package/lib/skuba.js.map +3 -3
- package/lib/utils/args.js +43 -6
- package/lib/utils/args.js.map +2 -2
- package/lib/utils/command.js +42 -4
- package/lib/utils/command.js.map +3 -3
- package/lib/utils/copy.js +57 -20
- package/lib/utils/copy.js.map +2 -2
- package/lib/utils/dir.js +72 -32
- package/lib/utils/dir.js.map +2 -2
- package/lib/utils/env.js +26 -2
- package/lib/utils/env.js.map +1 -1
- package/lib/utils/error.js +47 -10
- package/lib/utils/error.js.map +1 -1
- package/lib/utils/exec.js +61 -23
- package/lib/utils/exec.js.map +3 -3
- package/lib/utils/fs.js +40 -6
- package/lib/utils/fs.js.map +2 -2
- package/lib/utils/help.js +30 -6
- package/lib/utils/help.js.map +1 -1
- package/lib/utils/logging.js +38 -11
- package/lib/utils/logging.js.map +1 -1
- package/lib/utils/logo.js +48 -24
- package/lib/utils/logo.js.map +1 -1
- package/lib/utils/manifest.d.ts +2 -3
- package/lib/utils/manifest.js +48 -8
- package/lib/utils/manifest.js.map +3 -3
- package/lib/utils/npmrc.js +26 -2
- package/lib/utils/npmrc.js.map +1 -1
- package/lib/utils/packageManager.js +49 -12
- package/lib/utils/packageManager.js.map +2 -2
- package/lib/utils/port.js +39 -4
- package/lib/utils/port.js.map +2 -2
- package/lib/utils/sleep.js +26 -2
- package/lib/utils/sleep.js.map +1 -1
- package/lib/utils/template.js +55 -18
- package/lib/utils/template.js.map +3 -3
- package/lib/utils/validation.js +31 -2
- package/lib/utils/validation.js.map +1 -1
- package/lib/utils/version.js +46 -9
- package/lib/utils/version.js.map +2 -2
- package/lib/utils/wait.js +32 -7
- package/lib/utils/wait.js.map +1 -1
- package/lib/utils/worker.js +35 -10
- package/lib/utils/worker.js.map +1 -1
- package/lib/wrapper/function-arguments.d.js +1 -0
- package/lib/wrapper/functionHandler.js +49 -18
- package/lib/wrapper/functionHandler.js.map +2 -2
- package/lib/wrapper/http.js +43 -8
- package/lib/wrapper/http.js.map +2 -2
- package/lib/wrapper/index.js +7 -6
- package/lib/wrapper/index.js.map +1 -1
- package/lib/wrapper/main.js +42 -8
- package/lib/wrapper/main.js.map +3 -3
- package/lib/wrapper/requestListener.js +47 -13
- package/lib/wrapper/requestListener.js.map +2 -2
- package/lib/wrapper/server.js +28 -4
- package/lib/wrapper/server.js.map +1 -1
- package/package.json +42 -43
- package/template/base/_.prettierrc.js +1 -1
- package/template/base/_eslint.config.js +1 -1
- package/template/base/_pnpm-workspace.yaml +4 -3
- package/template/base/jest.config.ts +19 -0
- package/template/base/jest.setup.ts +3 -0
- package/template/express-rest-api/.buildkite/pipeline.yml +1 -1
- package/template/express-rest-api/.nvmrc +1 -1
- package/template/express-rest-api/package.json +7 -8
- package/template/express-rest-api/skuba.template.js +1 -1
- package/template/express-rest-api/src/app.test.ts +0 -1
- package/template/greeter/.buildkite/pipeline.yml +1 -1
- package/template/greeter/.nvmrc +1 -1
- package/template/greeter/package.json +4 -5
- package/template/greeter/skuba.template.js +1 -1
- package/template/greeter/src/app.test.ts +1 -3
- package/template/koa-rest-api/.buildkite/pipeline.yml +1 -1
- package/template/koa-rest-api/.nvmrc +1 -1
- package/template/koa-rest-api/package.json +8 -10
- package/template/koa-rest-api/skuba.template.js +1 -1
- package/template/koa-rest-api/src/api/jobs/getJobs.test.ts +0 -2
- package/template/koa-rest-api/src/api/jobs/postJob.test.ts +0 -2
- package/template/koa-rest-api/src/app.test.ts +0 -2
- package/template/koa-rest-api/src/framework/server.test.ts +2 -2
- package/template/koa-rest-api/src/framework/validation.test.ts +0 -2
- package/template/koa-rest-api/src/testing/metrics.ts +0 -2
- package/template/lambda-sqs-worker-cdk/.buildkite/pipeline.yml +2 -2
- package/template/lambda-sqs-worker-cdk/.nvmrc +1 -1
- package/template/lambda-sqs-worker-cdk/infra/__snapshots__/appStack.test.ts.snap +7 -21
- package/template/lambda-sqs-worker-cdk/infra/appStack.test.ts +9 -11
- package/template/lambda-sqs-worker-cdk/infra/appStack.ts +3 -3
- package/template/lambda-sqs-worker-cdk/infra/config.ts +2 -4
- package/template/lambda-sqs-worker-cdk/package.json +9 -9
- package/template/lambda-sqs-worker-cdk/skuba.template.js +13 -1
- package/template/lambda-sqs-worker-cdk/src/app.test.ts +13 -22
- package/template/lambda-sqs-worker-cdk/src/framework/handler.test.ts +0 -1
- package/template/lambda-sqs-worker-cdk/src/framework/validation.test.ts +31 -33
- package/template/lambda-sqs-worker-cdk/src/services/jobScorer.test.ts +2 -8
- package/template/lambda-sqs-worker-cdk/src/services/pipelineEventSender.test.ts +2 -3
- package/template/lambda-sqs-worker-cdk/src/testing/services.ts +3 -4
- package/template/oss-npm-package/.github/workflows/release.yml +1 -1
- package/template/oss-npm-package/.github/workflows/validate.yml +1 -1
- package/template/oss-npm-package/.nvmrc +1 -1
- package/template/oss-npm-package/_package.json +0 -1
- package/template/oss-npm-package/skuba.template.js +1 -1
- package/template/oss-npm-package/src/index.test.ts +0 -2
- package/template/private-npm-package/.nvmrc +1 -1
- package/template/private-npm-package/_package.json +1 -2
- package/template/private-npm-package/skuba.template.js +2 -2
- package/template/private-npm-package/src/index.test.ts +0 -2
- package/lib/cli/lint/internalLints/upgrade/patches/12.5.0/index.js +0 -11
- package/lib/cli/lint/internalLints/upgrade/patches/12.5.0/index.js.map +0 -7
- package/lib/cli/lint/internalLints/upgrade/patches/12.5.0/rewriteGlobalVars.d.ts +0 -5
- package/lib/cli/lint/internalLints/upgrade/patches/12.5.0/rewriteGlobalVars.js +0 -72
- package/lib/cli/lint/internalLints/upgrade/patches/12.5.0/rewriteGlobalVars.js.map +0 -7
- package/lib/cli/lint/internalLints/upgrade/patches/9.1.0/index.d.ts +0 -2
- package/lib/cli/lint/internalLints/upgrade/patches/9.1.0/index.js +0 -11
- package/lib/cli/lint/internalLints/upgrade/patches/9.1.0/index.js.map +0 -7
- package/lib/cli/lint/internalLints/upgrade/patches/9.1.0/upgradeNode.js +0 -34
- package/lib/cli/lint/internalLints/upgrade/patches/9.1.0/upgradeNode.js.map +0 -7
- package/lib/eslint.d.js +0 -1
- package/lib/eslint.d.js.map +0 -7
- package/template/base/vitest.config.ts +0 -25
- /package/lib/cli/lint/internalLints/upgrade/patches/{12.5.0 → 13.1.1}/index.d.ts +0 -0
- /package/lib/cli/lint/internalLints/upgrade/patches/{9.1.0 → 13.1.1}/upgradeNode.d.ts +0 -0
|
@@ -1,24 +1,58 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var files_exports = {};
|
|
30
|
+
__export(files_exports, {
|
|
31
|
+
tsFileExists: () => tsFileExists
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(files_exports);
|
|
34
|
+
var import_path = __toESM(require("path"));
|
|
35
|
+
var import_fs_extra = __toESM(require("fs-extra"));
|
|
36
|
+
var import_error = require("../../../utils/error.js");
|
|
4
37
|
const tsFileExists = async (filePath) => {
|
|
5
|
-
const ext =
|
|
38
|
+
const ext = import_path.default.extname(filePath);
|
|
6
39
|
if (ext !== "" && ext !== ".ts") {
|
|
7
40
|
return false;
|
|
8
41
|
}
|
|
9
42
|
try {
|
|
10
|
-
const stats = await
|
|
43
|
+
const stats = await import_fs_extra.default.promises.lstat(
|
|
11
44
|
ext === "" ? `${filePath}.ts` : filePath
|
|
12
45
|
);
|
|
13
46
|
return stats.isFile();
|
|
14
47
|
} catch (err) {
|
|
15
|
-
if (isErrorWithCode(err, "ENOENT")) {
|
|
48
|
+
if ((0, import_error.isErrorWithCode)(err, "ENOENT")) {
|
|
16
49
|
return false;
|
|
17
50
|
}
|
|
18
51
|
throw err;
|
|
19
52
|
}
|
|
20
53
|
};
|
|
21
|
-
export
|
|
54
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
55
|
+
0 && (module.exports = {
|
|
22
56
|
tsFileExists
|
|
23
|
-
};
|
|
57
|
+
});
|
|
24
58
|
//# sourceMappingURL=files.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/analysis/files.ts"],
|
|
4
4
|
"sourcesContent": ["import path from 'path';\n\nimport fs from 'fs-extra';\n\nimport { isErrorWithCode } from '../../../utils/error.js';\n\nexport const tsFileExists = async (filePath: string) => {\n const ext = path.extname(filePath);\n\n if (ext !== '' && ext !== '.ts') {\n return false;\n }\n\n try {\n const stats = await fs.promises.lstat(\n ext === '' ? `${filePath}.ts` : filePath,\n );\n\n return stats.isFile();\n } catch (err) {\n if (isErrorWithCode(err, 'ENOENT')) {\n return false;\n }\n\n throw err;\n }\n};\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": []
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,sBAAe;AAEf,mBAAgC;AAEzB,MAAM,eAAe,OAAO,aAAqB;AACtD,QAAM,MAAM,YAAAA,QAAK,QAAQ,QAAQ;AAEjC,MAAI,QAAQ,MAAM,QAAQ,OAAO;AAC/B,WAAO;AAAA,EACT;AAEA,MAAI;AACF,UAAM,QAAQ,MAAM,gBAAAC,QAAG,SAAS;AAAA,MAC9B,QAAQ,KAAK,GAAG,QAAQ,QAAQ;AAAA,IAClC;AAEA,WAAO,MAAM,OAAO;AAAA,EACtB,SAAS,KAAK;AACZ,YAAI,8BAAgB,KAAK,QAAQ,GAAG;AAClC,aAAO;AAAA,IACT;AAEA,UAAM;AAAA,EACR;AACF;",
|
|
6
|
+
"names": ["path", "fs"]
|
|
7
7
|
}
|
|
@@ -1,14 +1,47 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var git_exports = {};
|
|
30
|
+
__export(git_exports, {
|
|
31
|
+
auditWorkingTree: () => auditWorkingTree
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(git_exports);
|
|
34
|
+
var import_fs_extra = __toESM(require("fs-extra"));
|
|
35
|
+
var import_isomorphic_git = __toESM(require("isomorphic-git"));
|
|
36
|
+
var import_dir = require("../../../utils/dir.js");
|
|
37
|
+
var import_logging = require("../../../utils/logging.js");
|
|
5
38
|
const auditWorkingTree = async (dir) => {
|
|
6
|
-
const filepaths = await crawlDirectory(dir);
|
|
39
|
+
const filepaths = await (0, import_dir.crawlDirectory)(dir);
|
|
7
40
|
let anyFailed = false;
|
|
8
41
|
const statuses = await Promise.all(
|
|
9
42
|
filepaths.map(async (filepath) => {
|
|
10
43
|
try {
|
|
11
|
-
return await
|
|
44
|
+
return await import_isomorphic_git.default.status({ dir, fs: import_fs_extra.default, filepath });
|
|
12
45
|
} catch {
|
|
13
46
|
anyFailed = true;
|
|
14
47
|
return "absent";
|
|
@@ -18,16 +51,17 @@ const auditWorkingTree = async (dir) => {
|
|
|
18
51
|
if (statuses.some(
|
|
19
52
|
(status) => status !== "absent" && status !== "ignored" && status !== "unmodified"
|
|
20
53
|
)) {
|
|
21
|
-
log.newline();
|
|
22
|
-
log.warn("You have dirty/untracked files that may be overwritten.");
|
|
54
|
+
import_logging.log.newline();
|
|
55
|
+
import_logging.log.warn("You have dirty/untracked files that may be overwritten.");
|
|
23
56
|
} else if (anyFailed) {
|
|
24
|
-
log.newline();
|
|
25
|
-
log.warn(
|
|
57
|
+
import_logging.log.newline();
|
|
58
|
+
import_logging.log.warn(
|
|
26
59
|
"Some files failed to be read. Check that you don't have any dirty/untracked files that may be overwritten."
|
|
27
60
|
);
|
|
28
61
|
}
|
|
29
62
|
};
|
|
30
|
-
export
|
|
63
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
64
|
+
0 && (module.exports = {
|
|
31
65
|
auditWorkingTree
|
|
32
|
-
};
|
|
66
|
+
});
|
|
33
67
|
//# sourceMappingURL=git.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/analysis/git.ts"],
|
|
4
4
|
"sourcesContent": ["import fs from 'fs-extra';\nimport git from 'isomorphic-git';\n\nimport { crawlDirectory } from '../../../utils/dir.js';\nimport { log } from '../../../utils/logging.js';\n\nexport const auditWorkingTree = async (dir: string) => {\n const filepaths = await crawlDirectory(dir);\n\n let anyFailed = false;\n\n const statuses = await Promise.all(\n filepaths.map(async (filepath) => {\n try {\n return await git.status({ dir, fs, filepath });\n } catch {\n // TODO: Why does isomorphic-git sometimes just _fail_?\n anyFailed = true;\n return 'absent';\n }\n }),\n );\n\n if (\n statuses.some(\n (status) =>\n status !== 'absent' && status !== 'ignored' && status !== 'unmodified',\n )\n ) {\n log.newline();\n log.warn('You have dirty/untracked files that may be overwritten.');\n } else if (anyFailed) {\n log.newline();\n log.warn(\n \"Some files failed to be read. Check that you don't have any dirty/untracked files that may be overwritten.\",\n );\n }\n};\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": []
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,sBAAe;AACf,4BAAgB;AAEhB,iBAA+B;AAC/B,qBAAoB;AAEb,MAAM,mBAAmB,OAAO,QAAgB;AACrD,QAAM,YAAY,UAAM,2BAAe,GAAG;AAE1C,MAAI,YAAY;AAEhB,QAAM,WAAW,MAAM,QAAQ;AAAA,IAC7B,UAAU,IAAI,OAAO,aAAa;AAChC,UAAI;AACF,eAAO,MAAM,sBAAAA,QAAI,OAAO,EAAE,KAAK,oBAAAC,SAAI,SAAS,CAAC;AAAA,MAC/C,QAAQ;AAEN,oBAAY;AACZ,eAAO;AAAA,MACT;AAAA,IACF,CAAC;AAAA,EACH;AAEA,MACE,SAAS;AAAA,IACP,CAAC,WACC,WAAW,YAAY,WAAW,aAAa,WAAW;AAAA,EAC9D,GACA;AACA,uBAAI,QAAQ;AACZ,uBAAI,KAAK,yDAAyD;AAAA,EACpE,WAAW,WAAW;AACpB,uBAAI,QAAQ;AACZ,uBAAI;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACF;",
|
|
6
|
+
"names": ["git", "fs"]
|
|
7
7
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import
|
|
1
|
+
import readPkgUp from 'read-pkg-up';
|
|
2
|
+
import type { DependencyDiff } from '../types.js';
|
|
2
3
|
interface GetDestinationManifestProps {
|
|
3
4
|
cwd?: string;
|
|
4
5
|
}
|
|
5
|
-
export declare const getDestinationManifest: (props?: GetDestinationManifestProps) => Promise<ReadResult>;
|
|
6
|
+
export declare const getDestinationManifest: (props?: GetDestinationManifestProps) => Promise<readPkgUp.ReadResult>;
|
|
6
7
|
interface DiffDependenciesProps {
|
|
7
8
|
old: Record<string, string | undefined>;
|
|
8
9
|
new: Record<string, string | undefined>;
|
|
@@ -1,12 +1,46 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var package_exports = {};
|
|
30
|
+
__export(package_exports, {
|
|
31
|
+
diffDependencies: () => diffDependencies,
|
|
32
|
+
getDestinationManifest: () => getDestinationManifest
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(package_exports);
|
|
35
|
+
var import_read_pkg_up = __toESM(require("read-pkg-up"));
|
|
36
|
+
var import_logging = require("../../../utils/logging.js");
|
|
37
|
+
var import_diff = require("./diff.js");
|
|
4
38
|
const getDestinationManifest = async (props) => {
|
|
5
|
-
const result = await
|
|
39
|
+
const result = await (0, import_read_pkg_up.default)({ ...props, normalize: false });
|
|
6
40
|
if (result === void 0) {
|
|
7
|
-
log.err(
|
|
41
|
+
import_logging.log.err(
|
|
8
42
|
"Could not find a",
|
|
9
|
-
log.bold("package.json"),
|
|
43
|
+
import_logging.log.bold("package.json"),
|
|
10
44
|
"in your working directory."
|
|
11
45
|
);
|
|
12
46
|
process.exit(1);
|
|
@@ -21,7 +55,7 @@ const diffDependencies = (props) => {
|
|
|
21
55
|
return [];
|
|
22
56
|
}
|
|
23
57
|
const newVersion = props.new[name];
|
|
24
|
-
const operation = determineOperation(oldVersion, newVersion);
|
|
58
|
+
const operation = (0, import_diff.determineOperation)(oldVersion, newVersion);
|
|
25
59
|
const version = joinVersions(oldVersion, newVersion);
|
|
26
60
|
return [[name, { operation, version }]];
|
|
27
61
|
})
|
|
@@ -32,7 +66,7 @@ const diffDependencies = (props) => {
|
|
|
32
66
|
return [];
|
|
33
67
|
}
|
|
34
68
|
const oldVersion = props.old[name];
|
|
35
|
-
const operation = determineOperation(oldVersion, version);
|
|
69
|
+
const operation = (0, import_diff.determineOperation)(oldVersion, version);
|
|
36
70
|
return [[name, { operation, version }]];
|
|
37
71
|
})
|
|
38
72
|
);
|
|
@@ -41,8 +75,9 @@ const diffDependencies = (props) => {
|
|
|
41
75
|
...additions
|
|
42
76
|
};
|
|
43
77
|
};
|
|
44
|
-
export
|
|
78
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
79
|
+
0 && (module.exports = {
|
|
45
80
|
diffDependencies,
|
|
46
81
|
getDestinationManifest
|
|
47
|
-
};
|
|
82
|
+
});
|
|
48
83
|
//# sourceMappingURL=package.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/analysis/package.ts"],
|
|
4
|
-
"sourcesContent": ["import
|
|
5
|
-
"mappings": "AAAA,
|
|
6
|
-
"names": []
|
|
4
|
+
"sourcesContent": ["import readPkgUp from 'read-pkg-up';\n\nimport { log } from '../../../utils/logging.js';\nimport type { DependencyDiff } from '../types.js';\n\nimport { determineOperation } from './diff.js';\n\ninterface GetDestinationManifestProps {\n cwd?: string;\n}\n\nexport const getDestinationManifest = async (\n props?: GetDestinationManifestProps,\n) => {\n const result = await readPkgUp({ ...props, normalize: false });\n\n if (result === undefined) {\n log.err(\n 'Could not find a',\n log.bold('package.json'),\n 'in your working directory.',\n );\n process.exit(1);\n }\n\n return result;\n};\n\nconst joinVersions = (a: string | undefined, b: string | undefined) =>\n [a, b].filter((v) => v !== undefined).join(' -> ');\n\ninterface DiffDependenciesProps {\n old: Record<string, string | undefined>;\n new: Record<string, string | undefined>;\n}\n\nexport const diffDependencies = (\n props: DiffDependenciesProps,\n): DependencyDiff => {\n const deletionsAndModifications = Object.fromEntries(\n Object.entries(props.old).flatMap(([name, oldVersion]) => {\n if (oldVersion === props.new[name] || oldVersion === undefined) {\n return [];\n }\n\n const newVersion = props.new[name];\n\n const operation = determineOperation(oldVersion, newVersion);\n const version = joinVersions(oldVersion, newVersion);\n\n return [[name, { operation, version }]] as const;\n }),\n );\n\n const additions = Object.fromEntries(\n Object.entries(props.new).flatMap(([name, version]) => {\n if (name in props.old || version === undefined) {\n return [];\n }\n\n const oldVersion = props.old[name];\n\n const operation = determineOperation(oldVersion, version);\n\n return [[name, { operation, version }]] as const;\n }),\n );\n\n return {\n ...deletionsAndModifications,\n ...additions,\n };\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,yBAAsB;AAEtB,qBAAoB;AAGpB,kBAAmC;AAM5B,MAAM,yBAAyB,OACpC,UACG;AACH,QAAM,SAAS,UAAM,mBAAAA,SAAU,EAAE,GAAG,OAAO,WAAW,MAAM,CAAC;AAE7D,MAAI,WAAW,QAAW;AACxB,uBAAI;AAAA,MACF;AAAA,MACA,mBAAI,KAAK,cAAc;AAAA,MACvB;AAAA,IACF;AACA,YAAQ,KAAK,CAAC;AAAA,EAChB;AAEA,SAAO;AACT;AAEA,MAAM,eAAe,CAAC,GAAuB,MAC3C,CAAC,GAAG,CAAC,EAAE,OAAO,CAAC,MAAM,MAAM,MAAS,EAAE,KAAK,MAAM;AAO5C,MAAM,mBAAmB,CAC9B,UACmB;AACnB,QAAM,4BAA4B,OAAO;AAAA,IACvC,OAAO,QAAQ,MAAM,GAAG,EAAE,QAAQ,CAAC,CAAC,MAAM,UAAU,MAAM;AACxD,UAAI,eAAe,MAAM,IAAI,IAAI,KAAK,eAAe,QAAW;AAC9D,eAAO,CAAC;AAAA,MACV;AAEA,YAAM,aAAa,MAAM,IAAI,IAAI;AAEjC,YAAM,gBAAY,gCAAmB,YAAY,UAAU;AAC3D,YAAM,UAAU,aAAa,YAAY,UAAU;AAEnD,aAAO,CAAC,CAAC,MAAM,EAAE,WAAW,QAAQ,CAAC,CAAC;AAAA,IACxC,CAAC;AAAA,EACH;AAEA,QAAM,YAAY,OAAO;AAAA,IACvB,OAAO,QAAQ,MAAM,GAAG,EAAE,QAAQ,CAAC,CAAC,MAAM,OAAO,MAAM;AACrD,UAAI,QAAQ,MAAM,OAAO,YAAY,QAAW;AAC9C,eAAO,CAAC;AAAA,MACV;AAEA,YAAM,aAAa,MAAM,IAAI,IAAI;AAEjC,YAAM,gBAAY,gCAAmB,YAAY,OAAO;AAExD,aAAO,CAAC,CAAC,MAAM,EAAE,WAAW,QAAQ,CAAC,CAAC;AAAA,IACxC,CAAC;AAAA,EACH;AAEA,SAAO;AAAA,IACL,GAAG;AAAA,IACH,GAAG;AAAA,EACL;AACF;",
|
|
6
|
+
"names": ["readPkgUp"]
|
|
7
7
|
}
|
|
@@ -1,17 +1,48 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var project_exports = {};
|
|
30
|
+
__export(project_exports, {
|
|
31
|
+
createDestinationFileReader: () => createDestinationFileReader,
|
|
32
|
+
diffFiles: () => diffFiles
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(project_exports);
|
|
35
|
+
var import_path = __toESM(require("path"));
|
|
36
|
+
var import_fs_extra = __toESM(require("fs-extra"));
|
|
37
|
+
var import_dir = require("../../../utils/dir.js");
|
|
38
|
+
var import_error = require("../../../utils/error.js");
|
|
39
|
+
var import_modules = require("../modules/index.js");
|
|
40
|
+
var import_diff = require("./diff.js");
|
|
10
41
|
const createDestinationFileReader = (root) => async (filename) => {
|
|
11
42
|
try {
|
|
12
|
-
return await
|
|
43
|
+
return await import_fs_extra.default.promises.readFile(import_path.default.join(root, filename), "utf8");
|
|
13
44
|
} catch (err) {
|
|
14
|
-
if (isErrorWithCode(err, "ENOENT")) {
|
|
45
|
+
if ((0, import_error.isErrorWithCode)(err, "ENOENT")) {
|
|
15
46
|
return;
|
|
16
47
|
}
|
|
17
48
|
throw err;
|
|
@@ -19,9 +50,9 @@ const createDestinationFileReader = (root) => async (filename) => {
|
|
|
19
50
|
};
|
|
20
51
|
const loadModuleFiles = async (modules, destinationRoot) => {
|
|
21
52
|
const readDestinationFile = createDestinationFileReader(destinationRoot);
|
|
22
|
-
const allFilepaths = await crawlDirectory(destinationRoot);
|
|
53
|
+
const allFilepaths = await (0, import_dir.crawlDirectory)(destinationRoot);
|
|
23
54
|
const patterns = [...new Set(modules.flatMap((m) => Object.keys(m)))];
|
|
24
|
-
const patternToFilepaths = buildPatternToFilepathMap(patterns, allFilepaths);
|
|
55
|
+
const patternToFilepaths = (0, import_dir.buildPatternToFilepathMap)(patterns, allFilepaths);
|
|
25
56
|
const matchedFilepaths = [
|
|
26
57
|
...new Set(Object.values(patternToFilepaths).flat())
|
|
27
58
|
];
|
|
@@ -38,7 +69,7 @@ const loadModuleFiles = async (modules, destinationRoot) => {
|
|
|
38
69
|
const processTextFiles = async (modules, inputFiles, patternToFilepaths) => {
|
|
39
70
|
const outputFiles = { ...inputFiles };
|
|
40
71
|
const textProcessorEntries = modules.flatMap(
|
|
41
|
-
(
|
|
72
|
+
(module2) => Object.entries(module2).flatMap(([pattern, processText]) => {
|
|
42
73
|
const filepaths = [pattern, ...patternToFilepaths[pattern] ?? []];
|
|
43
74
|
return [...new Set(filepaths)].map(
|
|
44
75
|
(filepath) => [filepath, processText]
|
|
@@ -55,7 +86,7 @@ const processTextFiles = async (modules, inputFiles, patternToFilepaths) => {
|
|
|
55
86
|
return outputFiles;
|
|
56
87
|
};
|
|
57
88
|
const diffFiles = async (opts) => {
|
|
58
|
-
const modules = await loadModules(opts);
|
|
89
|
+
const modules = await (0, import_modules.loadModules)(opts);
|
|
59
90
|
const { inputFiles, patternToFilepaths } = Object.freeze(
|
|
60
91
|
await loadModuleFiles(modules, opts.destinationRoot)
|
|
61
92
|
);
|
|
@@ -65,13 +96,14 @@ const diffFiles = async (opts) => {
|
|
|
65
96
|
patternToFilepaths
|
|
66
97
|
);
|
|
67
98
|
const diffEntries = Object.entries(outputFiles).filter(([filepath, data]) => inputFiles[filepath] !== data).map(([filepath, data]) => {
|
|
68
|
-
const operation = determineOperation(inputFiles[filepath], data);
|
|
99
|
+
const operation = (0, import_diff.determineOperation)(inputFiles[filepath], data);
|
|
69
100
|
return [filepath, { data, operation }];
|
|
70
101
|
});
|
|
71
102
|
return Object.fromEntries(diffEntries);
|
|
72
103
|
};
|
|
73
|
-
export
|
|
104
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
105
|
+
0 && (module.exports = {
|
|
74
106
|
createDestinationFileReader,
|
|
75
107
|
diffFiles
|
|
76
|
-
};
|
|
108
|
+
});
|
|
77
109
|
//# sourceMappingURL=project.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/analysis/project.ts"],
|
|
4
4
|
"sourcesContent": ["import path from 'path';\n\nimport fs from 'fs-extra';\n\nimport {\n buildPatternToFilepathMap,\n crawlDirectory,\n} from '../../../utils/dir.js';\nimport { isErrorWithCode } from '../../../utils/error.js';\nimport { loadModules } from '../modules/index.js';\nimport type { FileDiff, Files, Module, Options } from '../types.js';\n\nimport { determineOperation } from './diff.js';\n\nexport const createDestinationFileReader =\n (root: string) =>\n async (filename: string): Promise<string | undefined> => {\n try {\n return await fs.promises.readFile(path.join(root, filename), 'utf8');\n } catch (err) {\n if (isErrorWithCode(err, 'ENOENT')) {\n return;\n }\n\n throw err;\n }\n };\n\nconst loadModuleFiles = async (modules: Module[], destinationRoot: string) => {\n const readDestinationFile = createDestinationFileReader(destinationRoot);\n\n const allFilepaths = await crawlDirectory(destinationRoot);\n\n const patterns = [...new Set(modules.flatMap((m) => Object.keys(m)))];\n\n const patternToFilepaths = buildPatternToFilepathMap(patterns, allFilepaths);\n\n const matchedFilepaths = [\n ...new Set(Object.values(patternToFilepaths).flat()),\n ];\n\n const fileEntries = await Promise.all(\n matchedFilepaths.map(\n async (filepath) =>\n [filepath, await readDestinationFile(filepath)] as const,\n ),\n );\n\n return {\n inputFiles: Object.fromEntries(fileEntries),\n patternToFilepaths,\n };\n};\n\nconst processTextFiles = async (\n modules: Module[],\n inputFiles: Readonly<Files>,\n patternToFilepaths: Record<string, string[]>,\n) => {\n const outputFiles = { ...inputFiles };\n\n const textProcessorEntries = modules.flatMap((module) =>\n Object.entries(module).flatMap(([pattern, processText]) => {\n // Include the raw pattern along with any matched filepaths.\n // Some modules create a new file at the specified pattern.\n const filepaths = [pattern, ...(patternToFilepaths[pattern] ?? [])];\n\n return [...new Set(filepaths)].map(\n (filepath) => [filepath, processText] as const,\n );\n }),\n );\n\n for (const [filepath, processText] of textProcessorEntries) {\n outputFiles[filepath] = await processText(\n outputFiles[filepath],\n outputFiles,\n inputFiles,\n );\n }\n\n return outputFiles;\n};\n\nexport const diffFiles = async (opts: Options): Promise<FileDiff> => {\n const modules = await loadModules(opts);\n\n const { inputFiles, patternToFilepaths } = Object.freeze(\n await loadModuleFiles(modules, opts.destinationRoot),\n );\n\n const outputFiles = await processTextFiles(\n modules,\n inputFiles,\n patternToFilepaths,\n );\n\n const diffEntries = Object.entries(outputFiles)\n .filter(([filepath, data]) => inputFiles[filepath] !== data)\n .map(([filepath, data]) => {\n const operation = determineOperation(inputFiles[filepath], data);\n\n return [filepath, { data, operation }] as const;\n });\n\n return Object.fromEntries(diffEntries);\n};\n"],
|
|
5
|
-
"mappings": "AAAA
|
|
6
|
-
"names": []
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AAEjB,sBAAe;AAEf,iBAGO;AACP,mBAAgC;AAChC,qBAA4B;AAG5B,kBAAmC;AAE5B,MAAM,8BACX,CAAC,SACD,OAAO,aAAkD;AACvD,MAAI;AACF,WAAO,MAAM,gBAAAA,QAAG,SAAS,SAAS,YAAAC,QAAK,KAAK,MAAM,QAAQ,GAAG,MAAM;AAAA,EACrE,SAAS,KAAK;AACZ,YAAI,8BAAgB,KAAK,QAAQ,GAAG;AAClC;AAAA,IACF;AAEA,UAAM;AAAA,EACR;AACF;AAEF,MAAM,kBAAkB,OAAO,SAAmB,oBAA4B;AAC5E,QAAM,sBAAsB,4BAA4B,eAAe;AAEvE,QAAM,eAAe,UAAM,2BAAe,eAAe;AAEzD,QAAM,WAAW,CAAC,GAAG,IAAI,IAAI,QAAQ,QAAQ,CAAC,MAAM,OAAO,KAAK,CAAC,CAAC,CAAC,CAAC;AAEpE,QAAM,yBAAqB,sCAA0B,UAAU,YAAY;AAE3E,QAAM,mBAAmB;AAAA,IACvB,GAAG,IAAI,IAAI,OAAO,OAAO,kBAAkB,EAAE,KAAK,CAAC;AAAA,EACrD;AAEA,QAAM,cAAc,MAAM,QAAQ;AAAA,IAChC,iBAAiB;AAAA,MACf,OAAO,aACL,CAAC,UAAU,MAAM,oBAAoB,QAAQ,CAAC;AAAA,IAClD;AAAA,EACF;AAEA,SAAO;AAAA,IACL,YAAY,OAAO,YAAY,WAAW;AAAA,IAC1C;AAAA,EACF;AACF;AAEA,MAAM,mBAAmB,OACvB,SACA,YACA,uBACG;AACH,QAAM,cAAc,EAAE,GAAG,WAAW;AAEpC,QAAM,uBAAuB,QAAQ;AAAA,IAAQ,CAACC,YAC5C,OAAO,QAAQA,OAAM,EAAE,QAAQ,CAAC,CAAC,SAAS,WAAW,MAAM;AAGzD,YAAM,YAAY,CAAC,SAAS,GAAI,mBAAmB,OAAO,KAAK,CAAC,CAAE;AAElE,aAAO,CAAC,GAAG,IAAI,IAAI,SAAS,CAAC,EAAE;AAAA,QAC7B,CAAC,aAAa,CAAC,UAAU,WAAW;AAAA,MACtC;AAAA,IACF,CAAC;AAAA,EACH;AAEA,aAAW,CAAC,UAAU,WAAW,KAAK,sBAAsB;AAC1D,gBAAY,QAAQ,IAAI,MAAM;AAAA,MAC5B,YAAY,QAAQ;AAAA,MACpB;AAAA,MACA;AAAA,IACF;AAAA,EACF;AAEA,SAAO;AACT;AAEO,MAAM,YAAY,OAAO,SAAqC;AACnE,QAAM,UAAU,UAAM,4BAAY,IAAI;AAEtC,QAAM,EAAE,YAAY,mBAAmB,IAAI,OAAO;AAAA,IAChD,MAAM,gBAAgB,SAAS,KAAK,eAAe;AAAA,EACrD;AAEA,QAAM,cAAc,MAAM;AAAA,IACxB;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAEA,QAAM,cAAc,OAAO,QAAQ,WAAW,EAC3C,OAAO,CAAC,CAAC,UAAU,IAAI,MAAM,WAAW,QAAQ,MAAM,IAAI,EAC1D,IAAI,CAAC,CAAC,UAAU,IAAI,MAAM;AACzB,UAAM,gBAAY,gCAAmB,WAAW,QAAQ,GAAG,IAAI;AAE/D,WAAO,CAAC,UAAU,EAAE,MAAM,UAAU,CAAC;AAAA,EACvC,CAAC;AAEH,SAAO,OAAO,YAAY,WAAW;AACvC;",
|
|
6
|
+
"names": ["fs", "path", "module"]
|
|
7
7
|
}
|
|
@@ -1,13 +1,41 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var dependencies_exports = {};
|
|
20
|
+
__export(dependencies_exports, {
|
|
21
|
+
seekDatadogCustomMetrics: () => import_seekDatadogCustomMetrics.seekDatadogCustomMetrics,
|
|
22
|
+
seekKoala: () => import_seekKoala.seekKoala,
|
|
23
|
+
skuba: () => import_skuba.skuba,
|
|
24
|
+
skubaDeps: () => import_skubaDeps.skubaDeps,
|
|
25
|
+
skubaDive: () => import_skubaDive.skubaDive
|
|
26
|
+
});
|
|
27
|
+
module.exports = __toCommonJS(dependencies_exports);
|
|
28
|
+
var import_seekDatadogCustomMetrics = require("./seekDatadogCustomMetrics.js");
|
|
29
|
+
var import_seekKoala = require("./seekKoala.js");
|
|
30
|
+
var import_skuba = require("./skuba.js");
|
|
31
|
+
var import_skubaDeps = require("./skubaDeps.js");
|
|
32
|
+
var import_skubaDive = require("./skubaDive.js");
|
|
33
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
34
|
+
0 && (module.exports = {
|
|
7
35
|
seekDatadogCustomMetrics,
|
|
8
36
|
seekKoala,
|
|
9
37
|
skuba,
|
|
10
38
|
skubaDeps,
|
|
11
39
|
skubaDive
|
|
12
|
-
};
|
|
40
|
+
});
|
|
13
41
|
//# sourceMappingURL=index.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/dependencies/index.ts"],
|
|
4
4
|
"sourcesContent": ["export { seekDatadogCustomMetrics } from './seekDatadogCustomMetrics.js';\nexport { seekKoala } from './seekKoala.js';\nexport { skuba } from './skuba.js';\nexport { skubaDeps } from './skubaDeps.js';\nexport { skubaDive } from './skubaDive.js';\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,sCAAyC;AACzC,uBAA0B;AAC1B,mBAAsB;AACtB,uBAA0B;AAC1B,uBAA0B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,4 +1,27 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var seekDatadogCustomMetrics_exports = {};
|
|
20
|
+
__export(seekDatadogCustomMetrics_exports, {
|
|
21
|
+
seekDatadogCustomMetrics: () => seekDatadogCustomMetrics
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(seekDatadogCustomMetrics_exports);
|
|
24
|
+
var import_module = require("../processing/module.js");
|
|
2
25
|
const OLD_NAME = "@seek/node-datadog-custom-metrics";
|
|
3
26
|
const NEW_NAME = "seek-datadog-custom-metrics";
|
|
4
27
|
const seekDatadogCustomMetrics = ({
|
|
@@ -17,7 +40,7 @@ const seekDatadogCustomMetrics = ({
|
|
|
17
40
|
delete devDependencies[OLD_NAME];
|
|
18
41
|
}
|
|
19
42
|
return [
|
|
20
|
-
replacePackageReferences({
|
|
43
|
+
(0, import_module.replacePackageReferences)({
|
|
21
44
|
old: {
|
|
22
45
|
packageName: OLD_NAME,
|
|
23
46
|
repoSlug: "seek-jobs/node-datadog-custom-metrics"
|
|
@@ -29,7 +52,8 @@ const seekDatadogCustomMetrics = ({
|
|
|
29
52
|
})
|
|
30
53
|
];
|
|
31
54
|
};
|
|
32
|
-
export
|
|
55
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
56
|
+
0 && (module.exports = {
|
|
33
57
|
seekDatadogCustomMetrics
|
|
34
|
-
};
|
|
58
|
+
});
|
|
35
59
|
//# sourceMappingURL=seekDatadogCustomMetrics.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/dependencies/seekDatadogCustomMetrics.ts"],
|
|
4
4
|
"sourcesContent": ["import { replacePackageReferences } from '../processing/module.js';\nimport type { DependencySet } from '../types.js';\n\nconst OLD_NAME = '@seek/node-datadog-custom-metrics';\nconst NEW_NAME = 'seek-datadog-custom-metrics';\n\nexport const seekDatadogCustomMetrics = ({\n dependencies,\n devDependencies,\n}: DependencySet) => {\n if (!dependencies[OLD_NAME] && !devDependencies[OLD_NAME]) {\n return [];\n }\n\n // lazily upgrade to latest version of the new package\n if (dependencies[OLD_NAME]) {\n dependencies[NEW_NAME] = '*';\n delete dependencies[OLD_NAME];\n }\n if (devDependencies[OLD_NAME]) {\n devDependencies[NEW_NAME] = '*';\n delete devDependencies[OLD_NAME];\n }\n\n return [\n replacePackageReferences({\n old: {\n packageName: OLD_NAME,\n repoSlug: 'seek-jobs/node-datadog-custom-metrics',\n },\n new: {\n packageName: NEW_NAME,\n repoSlug: 'seek-oss/datadog-custom-metrics',\n },\n }),\n ];\n};\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAAyC;AAGzC,MAAM,WAAW;AACjB,MAAM,WAAW;AAEV,MAAM,2BAA2B,CAAC;AAAA,EACvC;AAAA,EACA;AACF,MAAqB;AACnB,MAAI,CAAC,aAAa,QAAQ,KAAK,CAAC,gBAAgB,QAAQ,GAAG;AACzD,WAAO,CAAC;AAAA,EACV;AAGA,MAAI,aAAa,QAAQ,GAAG;AAC1B,iBAAa,QAAQ,IAAI;AACzB,WAAO,aAAa,QAAQ;AAAA,EAC9B;AACA,MAAI,gBAAgB,QAAQ,GAAG;AAC7B,oBAAgB,QAAQ,IAAI;AAC5B,WAAO,gBAAgB,QAAQ;AAAA,EACjC;AAEA,SAAO;AAAA,QACL,wCAAyB;AAAA,MACvB,KAAK;AAAA,QACH,aAAa;AAAA,QACb,UAAU;AAAA,MACZ;AAAA,MACA,KAAK;AAAA,QACH,aAAa;AAAA,QACb,UAAU;AAAA,MACZ;AAAA,IACF,CAAC;AAAA,EACH;AACF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,4 +1,27 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var seekKoala_exports = {};
|
|
20
|
+
__export(seekKoala_exports, {
|
|
21
|
+
seekKoala: () => seekKoala
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(seekKoala_exports);
|
|
24
|
+
var import_module = require("../processing/module.js");
|
|
2
25
|
const OLD_NAME = "@seek/koala";
|
|
3
26
|
const NEW_NAME = "seek-koala";
|
|
4
27
|
const seekKoala = ({ dependencies, devDependencies }) => {
|
|
@@ -14,7 +37,7 @@ const seekKoala = ({ dependencies, devDependencies }) => {
|
|
|
14
37
|
delete devDependencies[OLD_NAME];
|
|
15
38
|
}
|
|
16
39
|
return [
|
|
17
|
-
replacePackageReferences({
|
|
40
|
+
(0, import_module.replacePackageReferences)({
|
|
18
41
|
old: {
|
|
19
42
|
packageName: OLD_NAME,
|
|
20
43
|
repoSlug: "seek-jobs/koala"
|
|
@@ -26,7 +49,8 @@ const seekKoala = ({ dependencies, devDependencies }) => {
|
|
|
26
49
|
})
|
|
27
50
|
];
|
|
28
51
|
};
|
|
29
|
-
export
|
|
52
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
53
|
+
0 && (module.exports = {
|
|
30
54
|
seekKoala
|
|
31
|
-
};
|
|
55
|
+
});
|
|
32
56
|
//# sourceMappingURL=seekKoala.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/cli/configure/dependencies/seekKoala.ts"],
|
|
4
4
|
"sourcesContent": ["import { replacePackageReferences } from '../processing/module.js';\nimport type { DependencySet } from '../types.js';\n\nconst OLD_NAME = '@seek/koala';\nconst NEW_NAME = 'seek-koala';\n\nexport const seekKoala = ({ dependencies, devDependencies }: DependencySet) => {\n if (!dependencies[OLD_NAME] && !devDependencies[OLD_NAME]) {\n return [];\n }\n\n // lazily upgrade to latest version of the new package\n if (dependencies[OLD_NAME]) {\n dependencies[NEW_NAME] = '*';\n delete dependencies[OLD_NAME];\n }\n if (devDependencies[OLD_NAME]) {\n devDependencies[NEW_NAME] = '*';\n delete devDependencies[OLD_NAME];\n }\n\n return [\n replacePackageReferences({\n old: {\n packageName: OLD_NAME,\n repoSlug: 'seek-jobs/koala',\n },\n new: {\n packageName: NEW_NAME,\n repoSlug: 'seek-oss/koala',\n },\n }),\n ];\n};\n"],
|
|
5
|
-
"mappings": "AAAA,
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAAyC;AAGzC,MAAM,WAAW;AACjB,MAAM,WAAW;AAEV,MAAM,YAAY,CAAC,EAAE,cAAc,gBAAgB,MAAqB;AAC7E,MAAI,CAAC,aAAa,QAAQ,KAAK,CAAC,gBAAgB,QAAQ,GAAG;AACzD,WAAO,CAAC;AAAA,EACV;AAGA,MAAI,aAAa,QAAQ,GAAG;AAC1B,iBAAa,QAAQ,IAAI;AACzB,WAAO,aAAa,QAAQ;AAAA,EAC9B;AACA,MAAI,gBAAgB,QAAQ,GAAG;AAC7B,oBAAgB,QAAQ,IAAI;AAC5B,WAAO,gBAAgB,QAAQ;AAAA,EACjC;AAEA,SAAO;AAAA,QACL,wCAAyB;AAAA,MACvB,KAAK;AAAA,QACH,aAAa;AAAA,QACb,UAAU;AAAA,MACZ;AAAA,MACA,KAAK;AAAA,QACH,aAAa;AAAA,QACb,UAAU;AAAA,MACZ;AAAA,IACF,CAAC;AAAA,EACH;AACF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|