Skip to content

[pull] main from mdn:main #17

[pull] main from mdn:main

[pull] main from mdn:main #17

name: Update MDN urls

Check failure on line 1 in .github/workflows/update-mdn-urls.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/update-mdn-urls.yml

Invalid workflow file

you may only define one of `paths` and `paths-ignore` for a single event
on:
pull_request_target:
types:
- opened
paths:
- "package.json"
paths-ignore:
- "**/*.json"
jobs:
update-mdn-urls:
if: github.repository == 'mdn/browser-compat-data' && startsWith(github.head_ref, 'dependabot/npm_and_yarn/ddbeck/mdn-content-inventory-')
name: Update MDN urls
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
token: ${{ secrets.GH_TOKEN }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: npm
- name: "Setup git"
run: |
git config user.email 108879845+mdn-bot@users.noreply.github.com
git config user.name mdn-bot
- name: Install
run: npm ci
- name: Update
run: |
npm run lint:fix -- --only=mdn_urls
if git diff --exit-code; then
echo "No changes."
else
git commit -m 'chore: fix mdn urls' .
git push
fi