diff --git a/.github/workflows/auto-start-ci.yml b/.github/workflows/auto-start-ci.yml deleted file mode 100644 index 04a620249f0225..00000000000000 --- a/.github/workflows/auto-start-ci.yml +++ /dev/null @@ -1,64 +0,0 @@ ---- -name: Auto Start CI - -on: - schedule: - # Runs every five minutes (fastest the scheduler can run). Five minutes is - # optimistic, it can take longer to run. - # To understand why `schedule` is used instead of other events, refer to - # ./doc/guides/commit-queue.md - - cron: "*/5 * * * *" - -env: - NODE_VERSION: 14.x - -jobs: - startCI: - if: github.repository == 'nodejs/node' - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - # Install dependencies - - name: Install Node.js - uses: actions/setup-node@v2-beta - with: - node-version: ${{ env.NODE_VERSION }} - - name: Install node-core-utils - run: npm install -g node-core-utils - - - name: Set variables - run: | - echo "REPOSITORY=$(echo ${{ github.repository }} | cut -d/ -f2)" >> $GITHUB_ENV - echo "OWNER=${{ github.repository_owner }}" >> $GITHUB_ENV - - # Get Pull Requests - - name: Get Pull Requests - uses: octokit/graphql-action@v2.x - id: get_prs_for_ci - with: - query: | - query prs($owner:String!, $repo:String!) { - repository(owner:$owner, name:$repo) { - pullRequests(labels: ["request-ci"], states: OPEN, last: 100) { - nodes { - number - } - } - } - } - owner: ${{ env.OWNER }} - repo: ${{ env.REPOSITORY }} - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Setup node-core-utils - run: | - ncu-config set username ${{ secrets.JENKINS_USER }} - ncu-config set token none - ncu-config set jenkins_token ${{ secrets.JENKINS_TOKEN }} - ncu-config set owner ${{ env.OWNER }} - ncu-config set repo ${{ env.REPOSITORY }} - - - name: Start CI - run: ./tools/actions/start-ci.sh ${{ secrets.GITHUB_TOKEN }} ${{ env.OWNER }} ${{ env.REPOSITORY }} $(echo '${{ steps.get_prs_for_ci.outputs.data }}' | jq '.repository.pullRequests.nodes | map(.number) | .[]') diff --git a/.github/workflows/build-tarball.yml b/.github/workflows/build-tarball.yml deleted file mode 100644 index 7e91c8fd007284..00000000000000 --- a/.github/workflows/build-tarball.yml +++ /dev/null @@ -1,72 +0,0 @@ -name: Build from tarball - -on: - pull_request: - push: - branches: - - master - - v[0-9]+.x-staging - - v[0-9]+.x - -env: - FLAKY_TESTS: dontcare - -jobs: - build-tarball: - env: - PYTHON_VERSION: 3.9 - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Make tarball - run: | - export DISTTYPE=nightly - export DATESTRING=`date "+%Y-%m-%d"` - export COMMIT=$(git rev-parse --short=10 "$GITHUB_SHA") - ./configure && make tar -j8 SKIP_XZ=1 - mkdir tarballs - mv *.tar.gz tarballs - - name: Upload tarball artifact - uses: actions/upload-artifact@v1 - with: - name: tarballs - path: tarballs - test-tarball-linux: - env: - PYTHON_VERSION: 3.9 - needs: build-tarball - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Download tarball - uses: actions/download-artifact@v1 - with: - name: tarballs - - name: Extract tarball - run: | - tar xzf tarballs/*.tar.gz - echo "TAR_DIR=`basename tarballs/*.tar.gz .tar.gz`" >> $GITHUB_ENV - - name: Copy directories needed for testing - run: | - cp -r tools/node_modules $TAR_DIR/tools - cp -r tools/eslint-rules $TAR_DIR/tools - - name: Build - run: | - cd $TAR_DIR - make build-ci -j2 V=1 - - name: Test - run: | - cd $TAR_DIR - make run-ci -j2 V=1 TEST_CI_ARGS="-p dots" diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml deleted file mode 100644 index 8765d2d8d5cae5..00000000000000 --- a/.github/workflows/build-windows.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: build-windows - -on: - pull_request: - push: - branches: - - master - - canary - - v[0-9]+.x-staging - - v[0-9]+.x - -env: - PYTHON_VERSION: 3.9 - FLAKY_TESTS: dontcare - -jobs: - build-windows: - runs-on: windows-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Install deps - run: choco install nasm - - name: Environment Information - run: npx envinfo - - name: Build - run: ./vcbuild.bat diff --git a/.github/workflows/close-stalled.yml b/.github/workflows/close-stalled.yml deleted file mode 100644 index 1834d3ac2e6815..00000000000000 --- a/.github/workflows/close-stalled.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: Close stalled issues and PRs -on: - schedule: - - cron: "0 0 * * *" - -jobs: - stale: - runs-on: ubuntu-latest - steps: - - uses: actions/stale@v3 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - days-before-close: 30 - stale-pr-label: stalled - stale-issue-label: stalled - close-issue-message: Closing this because it has stalled. Feel free to reopen if this issue is still relevant, or to ping the collaborator who labelled it stalled if you have any questions. - close-pr-message: Closing this because it has stalled. Feel free to reopen if this PR is still relevant, or to ping the collaborator who labelled it stalled if you have any questions. - # used to filter issues to check whether or not should be closed, avoids hitting maximum operations allowed if needing to paginate through all open issues - only-labels: stalled - # max requests it will send per run to the GitHub API before it deliberately exits to avoid hitting API rate limits - operations-per-run: 500 - # deactivates automatic removal of stalled label if issue gets any activity - remove-stale-when-updated: false - # deactivates automatic stale labelling as we prefer to do that manually - days-before-stale: -1 diff --git a/.github/workflows/comment-stalled.yml b/.github/workflows/comment-stalled.yml deleted file mode 100644 index 62bd26f39eb72d..00000000000000 --- a/.github/workflows/comment-stalled.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: Comment on issues and PRs when labelled stalled -on: - issues: - types: [labeled] - pull_request_target: - types: [labeled] - -jobs: - staleComment: - runs-on: ubuntu-latest - steps: - - name: Post comment - if: github.event.label.name == 'stalled' - env: - COMMENTS_URL: ${{ github.event.issue.comments_url || github.event.pull_request.comments_url }} - run: | - curl -X POST $COMMENTS_URL \ - -H "Content-Type: application/json" \ - -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ - --data '{ "body": "This issue/PR was marked as stalled, it will be automatically closed in 30 days. If it should remain open, please leave a comment explaining why it should remain open." }' diff --git a/.github/workflows/commit-queue.yml b/.github/workflows/commit-queue.yml deleted file mode 100644 index 5b36a358c61533..00000000000000 --- a/.github/workflows/commit-queue.yml +++ /dev/null @@ -1,83 +0,0 @@ ---- -# This action requires the following secrets to be set on the repository: -# GH_USER_NAME: GitHub user whose Jenkins and GitHub token are defined below -# GH_USER_TOKEN: GitHub user token, to be used by ncu and to push changes -# JENKINS_TOKEN: Jenkins token, to be used to check CI status - -name: Commit Queue - -on: - # `schedule` event is used instead of `pull_request` because when a - # `pull_request` event is triggered on a PR from a fork, GITHUB_TOKEN will - # be read-only, and the Action won't have access to any other repository - # secrets, which it needs to access Jenkins API. - schedule: - - cron: "*/5 * * * *" - -env: - NODE_VERSION: 14.x - -jobs: - commitQueue: - if: github.repository == 'nodejs/node' - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - with: - # Needs the whole git history for ncu to work - # See https://github.com/nodejs/node-core-utils/pull/486 - fetch-depth: 0 - # A personal token is required because pushing with GITHUB_TOKEN will - # prevent commits from running CI after they land on master. It needs - # to be set here because `checkout` configures GitHub authentication - # for push as well. - token: ${{ secrets.GH_USER_TOKEN }} - - # Install dependencies - - name: Install Node.js - uses: actions/setup-node@v2-beta - with: - node-version: ${{ env.NODE_VERSION }} - - name: Install node-core-utils - run: npm install -g node-core-utils@latest - - - name: Set variables - run: | - echo "REPOSITORY=$(echo ${{ github.repository }} | cut -d/ -f2)" >> $GITHUB_ENV - echo "OWNER=${{ github.repository_owner }}" >> $GITHUB_ENV - - - name: Get Pull Requests - uses: octokit/graphql-action@v2.x - id: get_mergable_pull_requests - with: - query: | - query release($owner:String!,$repo:String!, $base_ref:String!) { - repository(owner:$owner, name:$repo) { - pullRequests(baseRefName: $base_ref, labels: ["commit-queue"], states: OPEN, last: 100) { - nodes { - number - } - } - } - } - owner: ${{ env.OWNER }} - repo: ${{ env.REPOSITORY }} - # Commit queue is only enabled for the default branch on the repository - # TODO(mmarchini): get the default branch programmatically instead of - # assuming `master` - base_ref: "master" - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Configure node-core-utils - run: | - ncu-config set branch master - ncu-config set upstream origin - ncu-config set username "${{ secrets.GH_USER_NAME }}" - ncu-config set token "${{ secrets.GH_USER_TOKEN }}" - ncu-config set jenkins_token "${{ secrets.JENKINS_TOKEN }}" - ncu-config set repo "${{ env.REPOSITORY }}" - ncu-config set owner "${{ env.OWNER }}" - - - name: Start the commit queue - run: ./tools/actions/commit-queue.sh ${{ env.OWNER }} ${{ env.REPOSITORY }} ${{ secrets.GITHUB_TOKEN }} $(echo '${{ steps.get_mergable_pull_requests.outputs.data }}' | jq '.repository.pullRequests.nodes | map(.number) | .[]') diff --git a/.github/workflows/license-builder.yml b/.github/workflows/license-builder.yml deleted file mode 100644 index 714aeb1c1499d5..00000000000000 --- a/.github/workflows/license-builder.yml +++ /dev/null @@ -1,22 +0,0 @@ -name: license update -on: - schedule: - # 00:00:00 every Monday - # https://crontab.guru/#0_0_*_*_1 - - cron: "0 0 * * 1" - workflow_dispatch: - -jobs: - update_routes: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - run: "./tools/license-builder.sh" # run the license builder tool - - uses: gr2m/create-or-update-pull-request-action@v1.x # create a PR or update the Action's existing PR - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - title: "doc: run license-builder" - body: "License is likely out of date. This is an automatically generated PR by the `license-builder.yml` GitHub Action, which runs `license-builder.sh` and submits a new PR or updates an existing PR." - commit-message: 'doc: run license-builder' - labels: meta diff --git a/.github/workflows/linters.yml b/.github/workflows/linters.yml deleted file mode 100644 index 14aed9bfddfdc3..00000000000000 --- a/.github/workflows/linters.yml +++ /dev/null @@ -1,87 +0,0 @@ -name: linters - -on: - pull_request: - push: - branches: - - master - - v[0-9]+.x-staging - - v[0-9]+.x - -env: - PYTHON_VERSION: 3.9 - NODE_VERSION: 14.x - -jobs: - lint-addon-docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js ${{ env.NODE_VERSION }} - uses: actions/setup-node@v1 - with: - node-version: ${{ env.NODE_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Lint addon docs - run: NODE=$(command -v node) make lint-addon-docs - lint-cpp: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Lint C/C++ files - run: make lint-cpp - lint-md: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js ${{ env.NODE_VERSION }} - uses: actions/setup-node@v1 - with: - node-version: ${{ env.NODE_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Lint docs - run: | - echo "::add-matcher::.github/workflows/remark-lint-problem-matcher.json" - NODE=$(command -v node) make lint-md - lint-js: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js ${{ env.NODE_VERSION }} - uses: actions/setup-node@v1 - with: - node-version: ${{ env.NODE_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Lint JavaScript files - run: NODE=$(command -v node) make lint-js - lint-py: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Lint Python - run: | - make lint-py-build || true - NODE=$(command -v node) make lint-py - - lint-codeowners: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: mszostok/codeowners-validator@v0.4.0 - with: - checks: "files,duppatterns" diff --git a/.github/workflows/misc.yml b/.github/workflows/misc.yml deleted file mode 100644 index 1444dff7262819..00000000000000 --- a/.github/workflows/misc.yml +++ /dev/null @@ -1,32 +0,0 @@ -name: misc - -on: - pull_request: - push: - branches: - - master - - v[0-9]+.x-staging - - v[0-9]+.x - -env: - NODE_VERSION: 14.x - -jobs: - build-docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js ${{ env.NODE_VERSION }} - uses: actions/setup-node@v1 - with: - node-version: ${{ env.NODE_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Build - run: NODE=$(command -v node) make doc-only - - uses: actions/upload-artifact@v1 - with: - name: docs - path: out/doc - - name: Check links - run: node tools/doc/checkLinks.js . diff --git a/.github/workflows/remark-lint-problem-matcher.json b/.github/workflows/remark-lint-problem-matcher.json deleted file mode 100644 index cfb281310a9a0f..00000000000000 --- a/.github/workflows/remark-lint-problem-matcher.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "problemMatcher": [ - { - "owner": "remark-lint", - "pattern": [ - { - "regexp": "^(?:\\x1b\\[\\d+m)*(.+?)(?:\\x1b\\[\\d+m)*$", - "file": 1 - }, - { - "regexp": "^\\s+(?:\\d+:\\d+-)?(\\d+):(\\d+)\\s+\\S*(error|warning|info)\\S*\\s+(.+)\\s+(\\S+)\\s+(?:\\S+)$", - "line": 1, - "column": 2, - "severity": 3, - "message": 4, - "code": 5, - "loop": true - } - ] - } - ] -} diff --git a/.github/workflows/test-linux.yml b/.github/workflows/test-linux.yml deleted file mode 100644 index f96e3a28a1e791..00000000000000 --- a/.github/workflows/test-linux.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: test-linux - -on: - pull_request: - push: - branches: - - master - - canary - - v[0-9]+.x-staging - - v[0-9]+.x - -env: - PYTHON_VERSION: 3.9 - FLAKY_TESTS: dontcare - -jobs: - test-linux: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Build - run: make build-ci -j2 V=1 CONFIG_FLAGS="--error-on-warn" - - name: Test - run: make run-ci -j2 V=1 TEST_CI_ARGS="-p dots" diff --git a/.github/workflows/test-macos.yml b/.github/workflows/test-macos.yml deleted file mode 100644 index 98a16c88699afa..00000000000000 --- a/.github/workflows/test-macos.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: test-macOS - -on: - pull_request: - push: - branches: - - master - - canary - - v[0-9]+.x-staging - - v[0-9]+.x - -env: - PYTHON_VERSION: 3.9 - FLAKY_TESTS: dontcare - -jobs: - test-macOS: - runs-on: macos-latest - steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ env.PYTHON_VERSION }} - uses: actions/setup-python@v2 - with: - python-version: ${{ env.PYTHON_VERSION }} - - name: Environment Information - run: npx envinfo - - name: Build - run: make build-ci -j2 V=1 CONFIG_FLAGS="--error-on-warn" - - name: Test - run: make run-ci -j2 V=1 TEST_CI_ARGS="-p dots"