Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deps: @npmcli/template-oss@3.2.2 #4639

Merged
merged 3 commits into from Mar 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
70 changes: 54 additions & 16 deletions .github/workflows/ci-docs.yml
@@ -1,3 +1,5 @@
# This file is automatically added by @npmcli/template-oss. Do not edit.

name: CI - docs

on:
Expand All @@ -22,26 +24,62 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup git user
run: |
git config --global user.email "ops+npm-cli@npmjs.com"
git config --global user.name "npm cli ops bot"
- uses: actions/setup-node@v3
with:
node-version: 16.x
- run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
node ./bin/npm-cli.js rebuild
- run: node ./bin/npm-cli.js run lint -w docs
env:
DEPLOY_VERSION: testing
node-version: 16
- name: Update npm to latest
run: npm i --prefer-online --no-fund --no-audit -g npm@latest
- run: npm -v
- run: npm i --ignore-scripts
- run: npm run lint -w docs

check_docs:
runs-on: ubuntu-latest
test:
strategy:
fail-fast: false
matrix:
node-version:
- 16
platform:
- os: ubuntu-latest
shell: bash
- os: macos-latest
shell: bash
- os: windows-latest
shell: cmd
runs-on: ${{ matrix.platform.os }}
defaults:
run:
shell: ${{ matrix.platform.shell }}
steps:
- uses: actions/checkout@v3
- name: Setup git user
run: |
git config --global user.email "ops+npm-cli@npmjs.com"
git config --global user.name "npm cli ops bot"
- uses: actions/setup-node@v3
with:
node-version: 16.x
- run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
- name: Rebuild the docs
run: make freshdocs
- name: Git should not be dirty
run: node scripts/git-dirty.js
node-version: ${{ matrix.node-version }}
- name: Update to workable npm (windows)
# node 12 and 14 ship with npm@6, which is known to fail when updating itself in windows
if: matrix.platform.os == 'windows-latest' && (startsWith(matrix.node-version, '12.') || startsWith(matrix.node-version, '14.'))
run: |
curl -sO https://registry.npmjs.org/npm/-/npm-7.5.4.tgz
tar xf npm-7.5.4.tgz
cd package
node lib/npm.js install --no-fund --no-audit -g ..\npm-7.5.4.tgz
cd ..
rmdir /s /q package
- name: Update npm to 7
# If we do test on npm 10 it needs npm7
if: startsWith(matrix.node-version, '10.')
run: npm i --prefer-online --no-fund --no-audit -g npm@7
- name: Update npm to latest
if: ${{ !startsWith(matrix.node-version, '10.') }}
run: npm i --prefer-online --no-fund --no-audit -g npm@latest
- run: npm -v
- run: npm i --ignore-scripts
- run: npm test --ignore-scripts -w docs
129 changes: 47 additions & 82 deletions .github/workflows/ci.yml
@@ -1,149 +1,114 @@
name: Node CI
name: CI - cli

on:
workflow_dispatch:
pull_request:
branches:
- '*'
push:
branches:
- latest
workflow_dispatch:

jobs:
lint:
runs-on: ubuntu-latest
steps:
# Checkout the npm/cli repo
- uses: actions/checkout@v2
- name: Use Node.js 14.x
uses: actions/setup-node@v2
- uses: actions/checkout@v3
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: 14.x
node-version: 16.x
cache: npm
- name: Install dependencies
run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
node ./bin/npm-cli.js rebuild
- name: Run linting
run: node ./bin/npm-cli.js run posttest
env:
DEPLOY_VERSION: testing
- run: node ./bin/npm-cli.js run resetdeps
- run: node ./bin/npm-cli.js run lint

check_docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 14.x
uses: actions/setup-node@v2
- uses: actions/checkout@v3
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: 14.x
node-version: 16.x
cache: npm
- name: Install dependencies
run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
- name: Rebuild the docs
run: make freshdocs
- name: Git should not be dirty
run: node scripts/git-dirty.js

- run: make freshdocs
- run: node scripts/git-dirty.js

licenses:
runs-on: ubuntu-latest
steps:
# Checkout the npm/cli repo
- uses: actions/checkout@v2
- name: Use Node.js 14.x
uses: actions/setup-node@v2
- uses: actions/checkout@v3
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: 14.x
node-version: 16.x
cache: npm
- name: Install dependencies
run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
node ./bin/npm-cli.js rebuild
- name: Validate licenses
run: node ./bin/npm-cli.js run licenses
- run: node ./bin/npm-cli.js run resetdeps
- run: node ./bin/npm-cli.js run licenses

smoke-tests:
strategy:
fail-fast: false
matrix:
node-version: [12.x, 14.x, 16.x]
node-version:
- 12.x
- 14.x
- 16.x
platform:
- os: ubuntu-latest
shell: bash
- os: macos-latest
shell: bash
- os: windows-latest
shell: bash
- os: windows-latest
shell: powershell

shell: cmd
runs-on: ${{ matrix.platform.os }}
defaults:
run:
shell: ${{ matrix.platform.shell }}

steps:
# Checkout the npm/cli repo
- uses: actions/checkout@v2

# Installs the specific version of Node.js
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: npm

# Run the installer script
- name: Install dependencies
run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
node ./bin/npm-cli.js rebuild

# Run the smoke tests
- name: Run Smoke tests
run: node ./bin/npm-cli.js run --ignore-scripts smoke-tests -- --no-check-coverage -t600 -Rbase -c
env:
DEPLOY_VERSION: testing
- run: node ./bin/npm-cli.js run resetdeps
- run: node ./bin/npm-cli.js run smoke-tests --ignore-scripts
- name: git status
if: matrix.platform.os != 'windows-latest'
run: node scripts/git-dirty.js
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to highlight that I could not get the git-dirty check to work on windows. I'm ok with that for now, but this might lead to problems for external contributors on windows.


test:
strategy:
fail-fast: false
matrix:
node-version: ['12.13.0', 12.x, '14.15.0', 14.x, '16.0.0', 16.x]
node-version:
- 12.13.0
- 12.x
- 14.15.0
- 14.x
- 16.0.0
- 16.x
platform:
- os: ubuntu-latest
shell: bash
- os: macos-latest
shell: bash
- os: windows-latest
shell: bash
- os: windows-latest
shell: powershell

shell: cmd
runs-on: ${{ matrix.platform.os }}
defaults:
run:
shell: ${{ matrix.platform.shell }}

steps:
# Checkout the npm/cli repo
- uses: actions/checkout@v2

# Installs the specific version of Node.js
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: npm

# Run the installer script
- name: Install dependencies
run: |
node ./bin/npm-cli.js install --ignore-scripts --no-audit
node ./bin/npm-cli.js rebuild

# Run the tests
- name: Run Tap tests
run: node ./bin/npm-cli.js run test --ignore-scripts -- -t600 -Rbase -c
- run: node ./bin/npm-cli.js run resetdeps
- run: node ./bin/npm-cli.js run test --ignore-scripts
- name: git status
if: matrix.platform.os != 'windows-latest'
run: node scripts/git-dirty.js
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmaccess.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmaccess
path: workspaces/libnpmaccess
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmdiff.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmdiff
path: workspaces/libnpmdiff
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmexec.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmexec
path: workspaces/libnpmexec
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmfund.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmfund
path: workspaces/libnpmfund
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmhook.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmhook
path: workspaces/libnpmhook
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmorg.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmorg
path: workspaces/libnpmorg
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmpack.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmpack
path: workspaces/libnpmpack
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmpublish.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmpublish
path: workspaces/libnpmpublish
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmsearch.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmsearch
path: workspaces/libnpmsearch
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmteam.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmteam
path: workspaces/libnpmteam
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-libnpmversion.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/libnpmversion
path: workspaces/libnpmversion
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-please-npmcli-arborist.yml
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
release-type: node
monorepo-tags: true
paths: workspaces/arborist
path: workspaces/arborist
changelog-types: >
[
{"type":"feat","section":"Features","hidden":false},
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Expand Up @@ -29,7 +29,6 @@
!/LICENSE
!/make.bat
!/Makefile
!/netlify.toml
!/package-lock.json
!/package.json
!/README.md
Expand Down