diff --git a/.github/workflows/ci-libnpmaccess.yml b/.github/workflows/ci-libnpmaccess.yml index 3e56273ade42b..009f310a1ff28 100644 --- a/.github/workflows/ci-libnpmaccess.yml +++ b/.github/workflows/ci-libnpmaccess.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmaccess/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmaccess/** schedule: diff --git a/.github/workflows/ci-libnpmdiff.yml b/.github/workflows/ci-libnpmdiff.yml index 6a74d24504739..ade3bcd5ba5f0 100644 --- a/.github/workflows/ci-libnpmdiff.yml +++ b/.github/workflows/ci-libnpmdiff.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmdiff/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmdiff/** schedule: diff --git a/.github/workflows/ci-libnpmexec.yml b/.github/workflows/ci-libnpmexec.yml index a75f741c7414e..368be0bbf020e 100644 --- a/.github/workflows/ci-libnpmexec.yml +++ b/.github/workflows/ci-libnpmexec.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmexec/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmexec/** schedule: diff --git a/.github/workflows/ci-libnpmfund.yml b/.github/workflows/ci-libnpmfund.yml index 8f9dfb9a18b20..fa51078acb9d0 100644 --- a/.github/workflows/ci-libnpmfund.yml +++ b/.github/workflows/ci-libnpmfund.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmfund/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmfund/** schedule: diff --git a/.github/workflows/ci-libnpmhook.yml b/.github/workflows/ci-libnpmhook.yml index ff923dc266994..c02f043064470 100644 --- a/.github/workflows/ci-libnpmhook.yml +++ b/.github/workflows/ci-libnpmhook.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmhook/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmhook/** schedule: diff --git a/.github/workflows/ci-libnpmorg.yml b/.github/workflows/ci-libnpmorg.yml index 0b02427902ff1..40392306cbcfb 100644 --- a/.github/workflows/ci-libnpmorg.yml +++ b/.github/workflows/ci-libnpmorg.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmorg/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmorg/** schedule: diff --git a/.github/workflows/ci-libnpmpack.yml b/.github/workflows/ci-libnpmpack.yml index 712a75df99f1c..ac19ee9453d51 100644 --- a/.github/workflows/ci-libnpmpack.yml +++ b/.github/workflows/ci-libnpmpack.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmpack/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmpack/** schedule: diff --git a/.github/workflows/ci-libnpmpublish.yml b/.github/workflows/ci-libnpmpublish.yml index 0fe5a8a2b5ebf..8ea422c2b6c4a 100644 --- a/.github/workflows/ci-libnpmpublish.yml +++ b/.github/workflows/ci-libnpmpublish.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmpublish/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmpublish/** schedule: diff --git a/.github/workflows/ci-libnpmsearch.yml b/.github/workflows/ci-libnpmsearch.yml index 2ae995a683317..563acea2d69e8 100644 --- a/.github/workflows/ci-libnpmsearch.yml +++ b/.github/workflows/ci-libnpmsearch.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmsearch/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmsearch/** schedule: diff --git a/.github/workflows/ci-libnpmteam.yml b/.github/workflows/ci-libnpmteam.yml index 6adb53c0c3e0f..6f3bcc328cbbe 100644 --- a/.github/workflows/ci-libnpmteam.yml +++ b/.github/workflows/ci-libnpmteam.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmteam/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmteam/** schedule: diff --git a/.github/workflows/ci-libnpmversion.yml b/.github/workflows/ci-libnpmversion.yml index 0e502ff4329f2..36c9d92f720e5 100644 --- a/.github/workflows/ci-libnpmversion.yml +++ b/.github/workflows/ci-libnpmversion.yml @@ -9,8 +9,8 @@ on: - workspaces/libnpmversion/** push: branches: - - main - latest + - release/v* paths: - workspaces/libnpmversion/** schedule: diff --git a/.github/workflows/ci-npmcli-arborist.yml b/.github/workflows/ci-npmcli-arborist.yml index cfd3d14bf3835..d3fa83220f8be 100644 --- a/.github/workflows/ci-npmcli-arborist.yml +++ b/.github/workflows/ci-npmcli-arborist.yml @@ -9,8 +9,8 @@ on: - workspaces/arborist/** push: branches: - - main - latest + - release/v* paths: - workspaces/arborist/** schedule: diff --git a/.github/workflows/ci-npmcli-config.yml b/.github/workflows/ci-npmcli-config.yml index a7a4a49e9fe2b..b8fc544b78032 100644 --- a/.github/workflows/ci-npmcli-config.yml +++ b/.github/workflows/ci-npmcli-config.yml @@ -9,8 +9,8 @@ on: - workspaces/config/** push: branches: - - main - latest + - release/v* paths: - workspaces/config/** schedule: diff --git a/.github/workflows/ci-npmcli-docs.yml b/.github/workflows/ci-npmcli-docs.yml index 705bdb953b04e..4df6fc17a0ce6 100644 --- a/.github/workflows/ci-npmcli-docs.yml +++ b/.github/workflows/ci-npmcli-docs.yml @@ -9,8 +9,8 @@ on: - docs/** push: branches: - - main - latest + - release/v* paths: - docs/** schedule: diff --git a/.github/workflows/ci-npmcli-mock-globals.yml b/.github/workflows/ci-npmcli-mock-globals.yml index 9ab65a816c35b..8028138959608 100644 --- a/.github/workflows/ci-npmcli-mock-globals.yml +++ b/.github/workflows/ci-npmcli-mock-globals.yml @@ -9,8 +9,8 @@ on: - mock-globals/** push: branches: - - main - latest + - release/v* paths: - mock-globals/** schedule: diff --git a/.github/workflows/ci-npmcli-mock-registry.yml b/.github/workflows/ci-npmcli-mock-registry.yml index 01832e08fb35d..e04bcf3013124 100644 --- a/.github/workflows/ci-npmcli-mock-registry.yml +++ b/.github/workflows/ci-npmcli-mock-registry.yml @@ -9,8 +9,8 @@ on: - mock-registry/** push: branches: - - main - latest + - release/v* paths: - mock-registry/** schedule: diff --git a/.github/workflows/ci-npmcli-smoke-tests.yml b/.github/workflows/ci-npmcli-smoke-tests.yml index 68de458721e3c..ff66b993a0cc3 100644 --- a/.github/workflows/ci-npmcli-smoke-tests.yml +++ b/.github/workflows/ci-npmcli-smoke-tests.yml @@ -9,8 +9,8 @@ on: - smoke-tests/** push: branches: - - main - latest + - release/v* paths: - smoke-tests/** schedule: diff --git a/.github/workflows/ci-release.yml b/.github/workflows/ci-release.yml index 5361cd8518b5d..d3dde52f5979a 100644 --- a/.github/workflows/ci-release.yml +++ b/.github/workflows/ci-release.yml @@ -61,7 +61,7 @@ jobs: return { summary } - name: Create Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 id: check if: inputs.check-sha with: @@ -92,7 +92,7 @@ jobs: - name: Post Lint run: node . run postlint --ignore-scripts -ws -iwr --if-present - name: Conclude Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 if: steps.check.outputs.check_id && always() with: token: ${{ secrets.GITHUB_TOKEN }} @@ -161,7 +161,7 @@ jobs: return { summary } - name: Create Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 id: check if: inputs.check-sha with: @@ -194,7 +194,7 @@ jobs: - name: Check Git Status run: node scripts/git-dirty.js - name: Conclude Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 if: steps.check.outputs.check_id && always() with: token: ${{ secrets.GITHUB_TOKEN }} @@ -264,7 +264,7 @@ jobs: return { summary } - name: Create Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 id: check if: inputs.check-sha with: @@ -312,7 +312,7 @@ jobs: exit 1 fi - name: Conclude Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 if: steps.check.outputs.check_id && always() with: token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 53c86026355ba..17b79459c3740 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,8 +13,8 @@ on: - workspaces/** push: branches: - - main - latest + - release/v* paths-ignore: - docs/** - smoke-tests/** diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 66b9498a685b9..5552d66cb196b 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -5,12 +5,12 @@ name: CodeQL on: push: branches: - - main - latest + - release/v* pull_request: branches: - - main - latest + - release/v* schedule: # "At 10:00 UTC (03:00 PT) on Monday" https://crontab.guru/#0_10_*_*_1 - cron: "0 10 * * 1" diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 1d9fd2b13eb4b..b01e071059e4b 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -43,5 +43,7 @@ jobs: npx --offline commitlint -V --from 'origin/${{ github.base_ref }}' --to ${{ github.event.pull_request.head.sha }} - name: Run Commitlint on PR Title if: steps.commit.outcome == 'failure' + env: + PR_TITLE: ${{ github.event.pull_request.title }} run: | - echo '${{ github.event.pull_request.title }}' | npx --offline commitlint -V + echo "$PR_TITLE" | npx --offline commitlint -V diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1584672aa2b61..4e5fde33cdf3c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,7 +10,6 @@ on: type: string push: branches: - - main - latest - release/v* @@ -77,7 +76,7 @@ jobs: let commentId = comments.find(c => c.user.login === 'github-actions[bot]' && c.body.startsWith(body))?.id body += `Release workflow run: ${workflow.html_url}\n\n#### Force CI to Update This Release\n\n` - body += `This PR will be updated and CI will run for every non-\`chore:\` commit that is pushed to \`latest\`. ` + body += `This PR will be updated and CI will run for every non-\`chore:\` commit that is pushed to \`${REF_NAME}\`. ` body += `To force CI to update this PR, run this command:\n\n` body += `\`\`\`\ngh workflow run release.yml -r ${REF_NAME} -R ${owner}/${repo} -f release-pr=${issue_number}\n\`\`\`` @@ -123,7 +122,7 @@ jobs: return { summary } - name: Create Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 id: check if: steps.release.outputs.pr-sha with: @@ -213,7 +212,7 @@ jobs: return { summary } - name: Create Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 id: check if: steps.commit.outputs.sha with: @@ -223,7 +222,7 @@ jobs: sha: ${{ steps.commit.outputs.sha }} output: ${{ steps.check-output.outputs.result }} - name: Conclude Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 if: needs.release.outputs.check-id && always() with: token: ${{ secrets.GITHUB_TOKEN }} @@ -261,7 +260,7 @@ jobs: fi echo "result=$result" >> $GITHUB_OUTPUT - name: Conclude Check - uses: LouisBrunner/checks-action@v1.3.1 + uses: LouisBrunner/checks-action@v1.6.0 if: needs.update.outputs.check-id && always() with: token: ${{ secrets.GITHUB_TOKEN }} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index eb2beb45f1e8a..91e6ed4f6d2b2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,3 +1,5 @@ + + # Contributing ## Code of Conduct diff --git a/docs/package.json b/docs/package.json index 78b62e540bfba..21b7922c17be9 100644 --- a/docs/package.json +++ b/docs/package.json @@ -23,7 +23,7 @@ "@isaacs/string-locale-compare": "^1.1.0", "@npmcli/config": "^6.1.7", "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "front-matter": "^4.0.2", "ignore-walk": "^6.0.1", "jsdom": "^21.1.0", @@ -57,7 +57,7 @@ "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", "ciVersions": "latest", "engines": "^14.17.0 || ^16.13.0 || >=18.0.0", - "version": "4.14.1", + "version": "4.18.0", "content": "../scripts/template-oss/index.js", "workspaceRepo": { "add": { diff --git a/mock-globals/package.json b/mock-globals/package.json index b67429f43c15b..6ea9b0c65936d 100644 --- a/mock-globals/package.json +++ b/mock-globals/package.json @@ -34,7 +34,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1" + "version": "4.18.0" }, "tap": { "branches": 89, @@ -48,7 +48,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.1", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.2" } } diff --git a/mock-registry/package.json b/mock-registry/package.json index 6ab00a246705a..530be56427040 100644 --- a/mock-registry/package.json +++ b/mock-registry/package.json @@ -34,7 +34,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1" + "version": "4.18.0" }, "tap": { "no-coverage": true, @@ -46,7 +46,7 @@ "devDependencies": { "@npmcli/arborist": "^6.1.1", "@npmcli/eslint-config": "^4.0.1", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "json-stringify-safe": "^5.0.1", "nock": "^13.3.0", "npm-package-arg": "^10.1.0", diff --git a/package-lock.json b/package-lock.json index 63c1dd75d7691..caf3500a7db9c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -165,7 +165,7 @@ "@npmcli/git": "^4.1.0", "@npmcli/mock-globals": "^1.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "@tufjs/repo-mock": "^1.3.1", "diff": "^5.1.0", "licensee": "^10.0.0", @@ -189,7 +189,7 @@ "@isaacs/string-locale-compare": "^1.1.0", "@npmcli/config": "^6.1.7", "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "front-matter": "^4.0.2", "ignore-walk": "^6.0.1", "jsdom": "^21.1.0", @@ -213,7 +213,7 @@ "license": "ISC", "devDependencies": { "@npmcli/eslint-config": "^4.0.1", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.2" }, "engines": { @@ -227,7 +227,7 @@ "devDependencies": { "@npmcli/arborist": "^6.1.1", "@npmcli/eslint-config": "^4.0.1", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "json-stringify-safe": "^5.0.1", "nock": "^13.3.0", "npm-package-arg": "^10.1.0", @@ -2548,9 +2548,9 @@ "link": true }, "node_modules/@npmcli/template-oss": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@npmcli/template-oss/-/template-oss-4.14.1.tgz", - "integrity": "sha512-Ln95z9CNDGluaABAxUW+SXaybahaBn+dDyYxPC0iAAauv/Soyv2gBGM16HT6nXio1NiJMspDm1aCo8ZTMssuFw==", + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@npmcli/template-oss/-/template-oss-4.18.0.tgz", + "integrity": "sha512-9YNatnLacvQpSKVjjxPLA7CLkVdc3ZkyrO8Uq6YlhTODyeY5rvlFL8nGZwl+LxDsO/FGQI+mOWB8kc4m9upZAQ==", "dev": true, "hasInstallScript": true, "dependencies": { @@ -2561,7 +2561,7 @@ "@npmcli/arborist": "^6.0.0", "@npmcli/git": "^4.0.0", "@npmcli/map-workspaces": "^3.0.0", - "@npmcli/package-json": "^3.0.0", + "@npmcli/package-json": "^4.0.0", "@octokit/rest": "^19.0.4", "diff": "^5.0.0", "glob": "^10.1.0", @@ -2572,6 +2572,7 @@ "just-deep-map-values": "^1.1.1", "just-diff": "^6.0.0", "lodash": "^4.17.21", + "minimatch": "^9.0.2", "npm-package-arg": "^10.0.0", "proc-log": "^3.0.0", "release-please": "npm:@npmcli/release-please@^14.2.6", @@ -2588,23 +2589,6 @@ "node": "^14.17.0 || ^16.13.0 || >=18.0.0" } }, - "node_modules/@npmcli/template-oss/node_modules/@npmcli/package-json": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/@npmcli/package-json/-/package-json-3.1.1.tgz", - "integrity": "sha512-+UW0UWOYFKCkvszLoTwrYGrjNrT8tI5Ckeb/h+Z1y1fsNJEctl7HmerA5j2FgmoqFaLI2gsA1X9KgMFqx/bRmA==", - "dev": true, - "dependencies": { - "@npmcli/git": "^4.1.0", - "glob": "^10.2.2", - "json-parse-even-better-errors": "^3.0.0", - "normalize-package-data": "^5.0.0", - "npm-normalize-package-bin": "^3.0.1", - "proc-log": "^3.0.0" - }, - "engines": { - "node": "^14.17.0 || ^16.13.0 || >=18.0.0" - } - }, "node_modules/@octokit/auth-token": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-3.0.3.tgz", @@ -15617,7 +15601,7 @@ "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-registry": "^1.0.0", "@npmcli/promise-spawn": "^6.0.2", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "http-proxy": "^1.18.1", "tap": "^16.3.4", "which": "^3.0.0" @@ -15670,7 +15654,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "benchmark": "^2.1.4", "minify-registry-metadata": "^3.0.0", "nock": "^13.3.0", @@ -15699,7 +15683,7 @@ "devDependencies": { "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-globals": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.4" }, "engines": { @@ -15716,7 +15700,7 @@ "devDependencies": { "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -15740,7 +15724,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.4" }, "engines": { @@ -15766,7 +15750,7 @@ "devDependencies": { "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "bin-links": "^4.0.1", "chalk": "^5.2.0", "just-extend": "^6.2.0", @@ -15785,7 +15769,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.4" }, "engines": { @@ -15801,7 +15785,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -15818,7 +15802,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "minipass": "^5.0.0", "nock": "^13.3.0", "tap": "^16.3.4" @@ -15838,7 +15822,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "spawk": "^1.7.1", "tap": "^16.3.4" @@ -15864,7 +15848,7 @@ "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-globals": "^1.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "lodash.clonedeep": "^4.5.0", "nock": "^13.3.0", "tap": "^16.3.4" @@ -15881,7 +15865,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -15898,7 +15882,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -15918,7 +15902,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "require-inject": "^1.4.4", "tap": "^16.3.4" }, diff --git a/package.json b/package.json index fb06968e833d0..5e3e7bc79b222 100644 --- a/package.json +++ b/package.json @@ -196,7 +196,7 @@ "@npmcli/git": "^4.1.0", "@npmcli/mock-globals": "^1.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "@tufjs/repo-mock": "^1.3.1", "diff": "^5.1.0", "licensee": "^10.0.0", @@ -249,7 +249,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "./scripts/template-oss/root.js" }, "license": "Artistic-2.0", diff --git a/scripts/template-oss/CONTRIBUTING.md b/scripts/template-oss/CONTRIBUTING.md new file mode 100644 index 0000000000000..eb2beb45f1e8a --- /dev/null +++ b/scripts/template-oss/CONTRIBUTING.md @@ -0,0 +1,91 @@ +# Contributing + +## Code of Conduct + +All interactions in the **npm** organization on GitHub are considered to be covered by our standard [Code of Conduct](https://docs.npmjs.com/policies/conduct). + +## Reporting Bugs + +When submitting a new bug report, please first [search](https://github.com/npm/cli/issues) for an existing or similar report & then use one of our existing [issue templates](https://github.com/npm/cli/issues/new/choose) if you believe you've come across a unique problem. Duplicate issues, or issues that don't use one of our templates may get closed without a response. + +## Development + +**1. Clone this repository...** + +```bash +$ git clone git@github.com:npm/cli.git npm +``` + +**2. Navigate into project & install development-specific dependencies...** + +```bash +$ cd ./npm && node . install +``` + +**3. Write some code &/or add some tests...** + +```bash +... +``` + +**4. Run tests & ensure they pass...** +``` +$ node . run test +``` + +**5. Open a [Pull Request](https://github.com/npm/cli/pulls) for your work & become the newest contributor to `npm`! 🎉** + +## Pull Request Conventions + +We use [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/). When opening a pull request, please be sure that either the pull request title, or each commit in the pull request, has one of the following prefixes: + + - `feat`: For when introducing a new feature. The result will be a new semver minor version of the package when it is next published. + - `fix`: For bug fixes. The result will be a new semver patch version of the package when it is next published. + - `docs`: For documentation updates. The result will be a new semver patch version of the package when it is next published. + - `chore`: For changes that do not affect the published module. Often these are changes to tests. The result will be *no* change to the version of the package when it is next published (as the commit does not affect the published version). + +## Test Coverage + +We use [`tap`](https://node-tap.org/) for testing & expect that every new feature or bug fix comes with corresponding tests that validate the solutions. Tap also reports on code coverage and it will fail if that drops below 100%. + +To run your repository's version of the npm cli on your local machine use the following commands: + +**npm commands:** +```bash +node . +``` + +**npx commands:** +```bash +node . exec +``` + +For example instead of: +```bash +npm exec -- +``` +Use: +```bash +node . exec -- +``` + + +## Performance & Benchmarks + +We've set up an automated [benchmark](https://github.com/npm/benchmarks) integration that will run against all Pull Requests; Posting back a comment with the results of the run. + +**Example:** + +![image](https://user-images.githubusercontent.com/2818462/72312698-e2e57f80-3656-11ea-9fcf-4a8f6b97b0d1.png) + +You can learn more about this tool, including how to run & configure it manually, [here](https://github.com/npm/benchmarks) + +## What _not_ to contribute? + +### Dependencies + +It should be noted that our team does not accept third-party dependency updates/PRs. We have a [release process](https://github.com/npm/cli/wiki/Release-Process) that includes checks to ensure dependencies are staying up-to-date & will ship security patches for CVEs as they occur. If you submit a PR trying to update our dependencies we will close it with or without a reference to these contribution guidelines. + +### Tools/Automation + +Our core team is responsible for the maintenance of the tooling/automation in this project & we ask collaborators to kindly not make changes to these when contributing (ex. `.github/*`, `.eslintrc.json`, `.licensee.json` etc.) diff --git a/scripts/template-oss/root.js b/scripts/template-oss/root.js index 8f4446ef99b46..7db1df05213b3 100644 --- a/scripts/template-oss/root.js +++ b/scripts/template-oss/root.js @@ -1,22 +1,26 @@ module.exports = { rootRepo: { add: { - '.github/workflows/ci.yml': 'ci.yml', - '.github/workflows/ci-release.yml': 'ci-release.yml', - '.github/workflows/create-node-pr.yml': 'create-node-pr.yml', - '.github/workflows/node-integration.yml': 'node-integration.yml', '.github/ISSUE_TEMPLATE/bug.yml': false, '.github/ISSUE_TEMPLATE/config.yml': false, '.github/dependabot.yml': false, + '.github/settings.yml': false, + '.github/workflows/ci-release.yml': 'ci-release.yml', + '.github/workflows/ci.yml': 'ci.yml', + '.github/workflows/create-node-pr.yml': 'create-node-pr.yml', + '.github/workflows/node-integration.yml': 'node-integration.yml', '.github/workflows/post-dependabot.yml': false, + 'CONTRIBUTING.md': 'CONTRIBUTING.md', }, }, workspaceRepo: { add: { - '.github/workflows/release.yml': false, - '.github/workflows/ci-release.yml': false, '.github/dependabot.yml': false, + '.github/settings.yml': false, + '.github/workflows/ci-release.yml': false, '.github/workflows/post-dependabot.yml': false, + '.github/workflows/release.yml': false, + 'CONTRIBUTING.md': 'CONTRIBUTING.md', }, }, lockfile: true, diff --git a/smoke-tests/package.json b/smoke-tests/package.json index 6bd9cee3e3152..d674ebee81e9d 100644 --- a/smoke-tests/package.json +++ b/smoke-tests/package.json @@ -21,7 +21,7 @@ "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-registry": "^1.0.0", "@npmcli/promise-spawn": "^6.0.2", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "http-proxy": "^1.18.1", "tap": "^16.3.4", "which": "^3.0.0" @@ -30,7 +30,7 @@ "license": "ISC", "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/arborist/package.json b/workspaces/arborist/package.json index 712d01b47b334..a9ec27bacb003 100644 --- a/workspaces/arborist/package.json +++ b/workspaces/arborist/package.json @@ -39,7 +39,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "benchmark": "^2.1.4", "minify-registry-metadata": "^3.0.0", "nock": "^13.3.0", @@ -91,7 +91,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" } } diff --git a/workspaces/config/package.json b/workspaces/config/package.json index 420981b4659fc..76d193ba23ec4 100644 --- a/workspaces/config/package.json +++ b/workspaces/config/package.json @@ -32,7 +32,7 @@ "devDependencies": { "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-globals": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.4" }, "dependencies": { @@ -50,6 +50,6 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1" + "version": "4.18.0" } } diff --git a/workspaces/libnpmaccess/package.json b/workspaces/libnpmaccess/package.json index 42ea3c661c291..713cf8c264c98 100644 --- a/workspaces/libnpmaccess/package.json +++ b/workspaces/libnpmaccess/package.json @@ -17,7 +17,7 @@ "devDependencies": { "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -41,7 +41,7 @@ ], "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmdiff/package.json b/workspaces/libnpmdiff/package.json index 2ef51fb8e03b7..ce6eb3531b32e 100644 --- a/workspaces/libnpmdiff/package.json +++ b/workspaces/libnpmdiff/package.json @@ -42,7 +42,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.4" }, "dependencies": { @@ -58,7 +58,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmexec/package.json b/workspaces/libnpmexec/package.json index 290d895f5ee60..95a1e246cac62 100644 --- a/workspaces/libnpmexec/package.json +++ b/workspaces/libnpmexec/package.json @@ -51,7 +51,7 @@ "devDependencies": { "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "bin-links": "^4.0.1", "chalk": "^5.2.0", "just-extend": "^6.2.0", @@ -73,7 +73,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" } } diff --git a/workspaces/libnpmfund/package.json b/workspaces/libnpmfund/package.json index 8e0b6d083715e..0c863c2f92203 100644 --- a/workspaces/libnpmfund/package.json +++ b/workspaces/libnpmfund/package.json @@ -41,7 +41,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "tap": "^16.3.4" }, "dependencies": { @@ -52,7 +52,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmhook/package.json b/workspaces/libnpmhook/package.json index bc439929e7c7a..05b34dda75c41 100644 --- a/workspaces/libnpmhook/package.json +++ b/workspaces/libnpmhook/package.json @@ -35,7 +35,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -44,7 +44,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmorg/package.json b/workspaces/libnpmorg/package.json index 0ee6abd7455a6..675d03b5b2437 100644 --- a/workspaces/libnpmorg/package.json +++ b/workspaces/libnpmorg/package.json @@ -28,7 +28,7 @@ ], "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "minipass": "^5.0.0", "nock": "^13.3.0", "tap": "^16.3.4" @@ -49,7 +49,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmpack/package.json b/workspaces/libnpmpack/package.json index 12cf7aa8ee3b1..d8861c337c4d9 100644 --- a/workspaces/libnpmpack/package.json +++ b/workspaces/libnpmpack/package.json @@ -23,7 +23,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "spawk": "^1.7.1", "tap": "^16.3.4" @@ -46,7 +46,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmpublish/package.json b/workspaces/libnpmpublish/package.json index 6ea6a7181b0b7..7c7533a82c735 100644 --- a/workspaces/libnpmpublish/package.json +++ b/workspaces/libnpmpublish/package.json @@ -26,7 +26,7 @@ "@npmcli/eslint-config": "^4.0.0", "@npmcli/mock-globals": "^1.0.0", "@npmcli/mock-registry": "^1.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "lodash.clonedeep": "^4.5.0", "nock": "^13.3.0", "tap": "^16.3.4" @@ -53,7 +53,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmsearch/package.json b/workspaces/libnpmsearch/package.json index e7dd7aca9baf1..32cb1f21b6422 100644 --- a/workspaces/libnpmsearch/package.json +++ b/workspaces/libnpmsearch/package.json @@ -26,7 +26,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -45,7 +45,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmteam/package.json b/workspaces/libnpmteam/package.json index 5558224050eec..33a77095fe848 100644 --- a/workspaces/libnpmteam/package.json +++ b/workspaces/libnpmteam/package.json @@ -16,7 +16,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "nock": "^13.3.0", "tap": "^16.3.4" }, @@ -39,7 +39,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" }, "tap": { diff --git a/workspaces/libnpmversion/package.json b/workspaces/libnpmversion/package.json index 7bae86d8afe22..469f9c2bc00d6 100644 --- a/workspaces/libnpmversion/package.json +++ b/workspaces/libnpmversion/package.json @@ -32,7 +32,7 @@ }, "devDependencies": { "@npmcli/eslint-config": "^4.0.0", - "@npmcli/template-oss": "4.14.1", + "@npmcli/template-oss": "4.18.0", "require-inject": "^1.4.4", "tap": "^16.3.4" }, @@ -48,7 +48,7 @@ }, "templateOSS": { "//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.", - "version": "4.14.1", + "version": "4.18.0", "content": "../../scripts/template-oss/index.js" } }