Skip to content

Hardhat-ledger v3 #6371

Hardhat-ledger v3

Hardhat-ledger v3 #6371

# Fails if a PR doesn't have a changeset and is not labeled
# as "no changeset needed"
name: Check that the PR has a changeset
on:
merge_group:
pull_request:
branches:
- main
- v2
types:
- opened
- synchronize
- reopened
- labeled
- unlabeled
jobs:
check-if-changeset:
name: Check that PR has a changeset
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v5
# We need to fetch the base ref because the pull request check inspects the diff between the head and the base ref
- run: git fetch origin "$GITHUB_BASE_REF":"$GITHUB_BASE_REF"
- name: Check if merge group is valid
if: github.event_name == 'merge_group'
run: node scripts/validate-merge-group.mjs
- name: Check if PR has a changeset
if: github.event_name == 'pull_request'
env:
GITHUB_EVENT_PULL_REQUEST_LABELS: ${{ toJson(github.event.pull_request.labels) }}
run: node scripts/validate-pull-request-changeset.mjs