diff --git a/.github/workflows/release.yml b/.github/workflows/experimental-release.yml similarity index 100% rename from .github/workflows/release.yml rename to .github/workflows/experimental-release.yml diff --git a/.github/workflows/node-ci.yml b/.github/workflows/node-ci.yml index 79251142..3341a217 100644 --- a/.github/workflows/node-ci.yml +++ b/.github/workflows/node-ci.yml @@ -18,8 +18,9 @@ jobs: strategy: matrix: node: - - 18.17.0 + - 18.19.0 - 20.6.1 + - 22.0.0 steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 - name: Setup node diff --git a/.lockfile-lintrc.json b/.lockfile-lintrc.json new file mode 100644 index 00000000..98c156ac --- /dev/null +++ b/.lockfile-lintrc.json @@ -0,0 +1,8 @@ +{ + "path": "package-lock.json", + "type": "npm", + "validate-https": true, + "allowed-hosts": [ + "npm" + ] +} diff --git a/.npmrc b/.npmrc index 32f5979c..f202bc4b 100644 --- a/.npmrc +++ b/.npmrc @@ -1 +1,2 @@ update-notifier=false +registry=https://registry.npmjs.org diff --git a/README.md b/README.md index 0278e13f..5da35634 100644 --- a/README.md +++ b/README.md @@ -96,7 +96,12 @@ const {scaffold, extendEslintConfig} = await import('./lib/index.mjs'); }, decisions => ({ ...javascriptPlugin, - scaffold: options =>javascriptPlugin.scaffold({...options, decisions, unitTestFrameworks: {}}) + scaffold: options => javascriptPlugin.scaffold({ + ...options, + decisions, + configs: {}, + plugins: {unitTestFrameworks: {}} + }) }) ); })(); @@ -153,7 +158,7 @@ $ npm test [license-link]: LICENSE -[license-badge]: https://img.shields.io/github/license/form8ion/eslint-config-extender.svg +[license-badge]: https://img.shields.io/github/license/form8ion/eslint-config-extender.svg?logo=opensourceinitiative [npm-link]: https://www.npmjs.com/package/@form8ion/eslint-config-extender diff --git a/example.js b/example.js index 5d8d4c64..6a3b7b97 100644 --- a/example.js +++ b/example.js @@ -68,7 +68,12 @@ stubbedFs({node_modules: stubbedNodeModules}); }, decisions => ({ ...javascriptPlugin, - scaffold: options => javascriptPlugin.scaffold({...options, decisions, unitTestFrameworks: {}}) + scaffold: options => javascriptPlugin.scaffold({ + ...options, + decisions, + configs: {}, + plugins: {unitTestFrameworks: {}} + }) }) ); })(); diff --git a/package-lock.json b/package-lock.json index 5f35c91a..2f5bed32 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,7 +11,7 @@ "dependencies": { "@form8ion/config-file": "^1.1.2", "@form8ion/core": "^4.7.1", - "@form8ion/javascript": "^12.0.0", + "@form8ion/javascript": "^13.0.0-beta.13", "@form8ion/javascript-core": "^11.0.0", "@form8ion/project": "^19.0.1", "deepmerge": "^4.2.2" @@ -50,7 +50,7 @@ "vitest": "2.1.1" }, "engines": { - "node": "^18.17.0 || >=20.6.1" + "node": "^18.19.0 || ^20.6.1 || >=22" } }, "node_modules/@ampproject/remapping": { @@ -1926,9 +1926,9 @@ } }, "node_modules/@form8ion/javascript": { - "version": "12.6.3", - "resolved": "https://registry.npmjs.org/@form8ion/javascript/-/javascript-12.6.3.tgz", - "integrity": "sha512-KureJuI6GXTyqeqWvmgun86xt857I45ZzIQPDedqQw1dNAG3wR5imLF7Uz1a3YBLHMOdmoBkifmCqCQizs7qNQ==", + "version": "13.0.0-beta.13", + "resolved": "https://registry.npmjs.org/@form8ion/javascript/-/javascript-13.0.0-beta.13.tgz", + "integrity": "sha512-WuroMSGaPtr3euMMsFjoGnkCBcV8icxVK9VnfEbHslSZTRHbWpVgBYbldQHnYdRrg5cQxjLCM9MPamOMro+esQ==", "license": "MIT", "dependencies": { "@form8ion/codecov": "^6.0.0", @@ -1938,13 +1938,13 @@ "@form8ion/eslint": "^6.1.0", "@form8ion/execa-wrapper": "^1.0.0-alpha.1", "@form8ion/husky": "^5.3.0", - "@form8ion/javascript-core": "^11.0.0", + "@form8ion/javascript-core": "^12.0.0-beta.1", "@form8ion/overridable-prompts": "^1.2.0", "@form8ion/prettier": "^2.0.0", "@hapi/hoek": "^11.0.0", "@travi/cli-messages": "^1.1.0", - "@travi/language-scaffolder-prompts": "^1.3.0", - "camelcase": "^6.2.1", + "@travi/language-scaffolder-prompts": "^2.0.0-beta.1", + "camelcase": "^8.0.0", "deepmerge": "^4.2.2", "filedirname": "^3.0.0", "ini": "^5.0.0", @@ -1957,7 +1957,7 @@ "validate-npm-package-name": "^5.0.0" }, "engines": { - "node": "^18.17.0 || >=20.6.1" + "node": "^18.19.0 || ^20.6.1 || >=22" } }, "node_modules/@form8ion/javascript-core": { @@ -1978,6 +1978,36 @@ "node": "^18.17 || >=20.6.1" } }, + "node_modules/@form8ion/javascript/node_modules/@form8ion/javascript-core": { + "version": "12.0.0-beta.1", + "resolved": "https://registry.npmjs.org/@form8ion/javascript-core/-/javascript-core-12.0.0-beta.1.tgz", + "integrity": "sha512-M8rKmabfRzAyc44JAOetWTtfP5z6LwkWgsvYYBqnz4SAW4XaaDWAtHxaOOoAiAi6rjObGGm5sBqPhccevNSKFQ==", + "license": "MIT", + "dependencies": { + "@form8ion/core": "^4.2.0", + "@form8ion/execa-wrapper": "^1.0.0-alpha.1", + "@form8ion/overridable-prompts": "^1.1.0", + "@hapi/hoek": "^11.0.0", + "@travi/cli-messages": "^1.0.4", + "deepmerge": "^4.2.2", + "semver": "^7.3.5" + }, + "engines": { + "node": "^18.17 || >=20.6.1" + } + }, + "node_modules/@form8ion/javascript/node_modules/camelcase": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-8.0.0.tgz", + "integrity": "sha512-8WB3Jcas3swSvjIeA2yvCJ+Miyz5l1ZmB6HFb9R1317dt9LCQoswg/BGrmAmkWVEszSrrg4RwmO46qIm2OEnSA==", + "license": "MIT", + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/@form8ion/overridable-prompts": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/@form8ion/overridable-prompts/-/overridable-prompts-1.2.0.tgz", @@ -4323,9 +4353,9 @@ } }, "node_modules/@travi/language-scaffolder-prompts": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@travi/language-scaffolder-prompts/-/language-scaffolder-prompts-1.3.0.tgz", - "integrity": "sha512-DaV6pRGTlXOt9ZDqp+yGm5Zw3iS0oV1LciLM8t2ibuseigynrIBvqKmpqkgXEu78Vu5wAAF3MEK34+lnmAbT2Q==", + "version": "2.0.0-beta.1", + "resolved": "https://registry.npmjs.org/@travi/language-scaffolder-prompts/-/language-scaffolder-prompts-2.0.0-beta.1.tgz", + "integrity": "sha512-xvi9s0KDB074Dbqm8OM21DleKAyF6l3JRcr2Q3ByY4mshOogFCiQWbgXXeNeE8z4ln2OAxbwaUiOU8ajwhOZkQ==", "license": "MIT", "peerDependencies": { "inquirer": "^6.0.0 || ^7.0.0 || ^8.0.0" @@ -6151,6 +6181,7 @@ "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", + "dev": true, "license": "MIT", "engines": { "node": ">=10" diff --git a/package.json b/package.json index e287d05a..e34cf562 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "version": "0.0.0-semantically-released", "type": "module", "engines": { - "node": "^18.17.0 || >=20.6.1" + "node": "^18.19.0 || ^20.6.1 || >=22" }, "author": "Matt Travi (https://matt.travi.org)", "repository": "form8ion/eslint-config-extender", @@ -17,16 +17,16 @@ "sideEffects": false, "scripts": { "test": "npm-run-all --print-label build --parallel lint:* --parallel test:*", - "lint:lockfile": "lockfile-lint --path package-lock.json --type npm --validate-https --allowed-hosts npm", + "lint:lockfile": "lockfile-lint", "lint:js": "eslint . --cache", - "lint:md": "NODE_OPTIONS=--loader=testdouble remark . --frail", + "lint:md": "remark . --frail", "pregenerate:md": "run-s build", - "generate:md": "NODE_OPTIONS=\"--loader=testdouble --enable-source-maps\" remark . --output", + "generate:md": "NODE_OPTIONS=--enable-source-maps remark . --output", "lint:sensitive": "ban", "pretest:integration:base": "run-s build", "lint:gherkin": "gherkin-lint", "test:integration": "run-s 'test:integration:base -- --profile noWip'", - "test:integration:base": "NODE_OPTIONS=\"--loader=testdouble --enable-source-maps\" DEBUG=any cucumber-js test/integration", + "test:integration:base": "NODE_OPTIONS=--enable-source-maps DEBUG=any cucumber-js test/integration", "test:integration:debug": "DEBUG=test run-s test:integration", "test:integration:wip": "run-s 'test:integration:base -- --profile wip'", "test:integration:wip:debug": "DEBUG=test run-s 'test:integration:wip'", @@ -42,7 +42,8 @@ "lint:peer": "npm ls >/dev/null", "prepare": "husky install", "lint:engines": "ls-engines", - "lint:publish": "publint --strict" + "lint:publish": "publint --strict", + "lint:js:fix": "run-s 'lint:js -- --fix'" }, "files": [ "example.js", @@ -52,10 +53,11 @@ "access": "public", "provenance": true }, + "packageManager": "npm@10.8.3+sha256.b7dc7eb48d7479b93668e913c7ad686ab2aa71c705d4a56b5323d1bffdba2972", "dependencies": { "@form8ion/config-file": "^1.1.2", "@form8ion/core": "^4.7.1", - "@form8ion/javascript": "^12.0.0", + "@form8ion/javascript": "^13.0.0-beta.13", "@form8ion/javascript-core": "^11.0.0", "@form8ion/project": "^19.0.1", "deepmerge": "^4.2.2" diff --git a/test/integration/features/step_definitions/common-steps.js b/test/integration/features/step_definitions/common-steps.js index 0c01e4b3..09995e4a 100644 --- a/test/integration/features/step_definitions/common-steps.js +++ b/test/integration/features/step_definitions/common-steps.js @@ -95,8 +95,10 @@ When('the high-level scaffolder is executed', async function () { decisions => ({ scaffold: options => scaffoldJs({ ...options, - unitTestFrameworks: {}, - packageTypes: {[pluginName]: {scaffolder: scaffoldEslintConfig}}, + plugins: { + unitTestFrameworks: {}, + packageTypes: {[pluginName]: {scaffold: scaffoldEslintConfig}} + }, configs: {eslint: {scope: `@${any.word()}`}}, decisions })