discourse/.github/workflows/dependabot-pnpm-dedupe.yml
dependabot[bot] 0d3fd0b1d9
Build(deps): Bump actions/checkout from 4 to 5 (#34227)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to
5.
- [Release notes](https://github.com/actions/checkout/releases)
-
[Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-11 22:39:43 +02:00

44 lines
1,003 B
YAML

name: Pnpm dedupe on Dependabot PRs
on:
push:
branches:
- "dependabot/npm_and_yarn/**/*"
paths:
- "pnpm-lock.yaml"
permissions:
contents: write
jobs:
deduplicate:
name: Deduplicate
if: github.actor == 'dependabot[bot]'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
fetch-depth: 1
token: ${{ secrets.GH_PUSH_TOKEN }}
- name: Set up pnpm
uses: pnpm/action-setup@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
- name: pnpm install
run: pnpm install --ignore-scripts --frozen-lockfile
- run: pnpm dedupe --ignore-scripts
- name: Git push
run: |
git config --global user.email "ci@ci.invalid"
git config --global user.name "Discourse CI"
git add pnpm-lock.yaml
git status
git commit -m "pnpm dedupe [dependabot skip]" && git push || echo "done"