mirror of
https://github.com/imjasonh/govulncheck-action
synced 2026-07-08 08:45:48 +00:00
Bumps the github-actions group with 1 update: [actions/checkout](https://github.com/actions/checkout). Updates `actions/checkout` from 6 to 7 - [Release notes](https://github.com/actions/checkout/releases) - [Commits](https://github.com/actions/checkout/compare/v6...v7) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '7' dependency-type: direct:production update-type: version-update:semver-major dependency-group: github-actions ... Signed-off-by: dependabot[bot] <support@github.com>
55 lines
1.6 KiB
YAML
55 lines
1.6 KiB
YAML
name: Dependabot auto-merge
|
|
|
|
on:
|
|
pull_request:
|
|
workflow_dispatch:
|
|
|
|
permissions:
|
|
contents: write
|
|
pull-requests: write
|
|
actions: write
|
|
|
|
jobs:
|
|
dependabot:
|
|
runs-on: ubuntu-latest
|
|
if: ${{ github.actor == 'dependabot[bot]' || startsWith(github.head_ref || github.ref_name, 'dependabot/') }}
|
|
steps:
|
|
- uses: actions/checkout@v7
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.ref || github.ref_name }}
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v6
|
|
with:
|
|
node-version: '20'
|
|
cache: 'npm'
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
- name: Rebuild dist
|
|
run: npm run build
|
|
|
|
- name: Commit and push changes
|
|
id: commit
|
|
run: |
|
|
if [ -n "$(git status --porcelain dist/)" ]; then
|
|
git config --global user.name "dependabot[bot]"
|
|
git config --global user.email "49699333+dependabot[bot]@users.noreply.github.com"
|
|
git add dist/
|
|
git commit -m "chore: rebuild dist"
|
|
git push
|
|
echo "pushed=true" >> "$GITHUB_OUTPUT"
|
|
fi
|
|
|
|
- name: Trigger CI
|
|
if: steps.commit.outputs.pushed == 'true'
|
|
run: gh workflow run ci.yml --ref ${{ github.event.pull_request.head.ref || github.ref_name }}
|
|
env:
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Enable auto-merge for Dependabot PRs
|
|
run: gh pr merge --auto --squash "$PR_URL"
|
|
env:
|
|
PR_URL: ${{ github.event.pull_request.html_url || github.ref_name }}
|
|
GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
|