Skip to content

Bump @types/node from 18.14.0 to 22.7.7 #46

Bump @types/node from 18.14.0 to 22.7.7

Bump @types/node from 18.14.0 to 22.7.7 #46

Workflow file for this run

name: Auto Merge Dependabot PRs
on:
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
jobs:
auto-merge:
runs-on: ubuntu-latest
if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]'
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Node.js (if your project uses Node.js)
uses: actions/setup-node@v3
with:
node-version: '16' # Or the version your project uses
- name: Install dependencies
run: npm install # Adapt this step to your project's dependency manager
- name: Run tests
run: npm test # Replace with your test command
- name: Merge Dependabot PR
uses: actions/github-script@v6
with:
script: |
const pr = context.payload.pull_request;
if (pr.user.login === 'dependabot[bot]' && pr.state === 'open' && pr.mergeable) {
const merge = await github.rest.pulls.merge({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: pr.number,
});
console.log('PR merged:', merge.data.merged);
} else {
console.log('PR not merged. Conditions not met.');
}