Skip to content

Commit

Permalink
ci: Configure pnpm/node before running browserslist update (#26703)
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaeelaudibert authored Dec 5, 2024
1 parent cc990fd commit 14ab46b
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions .github/workflows/browserslist-update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Update Browserslist database

on:
schedule:
- cron: '0 0 5,15,25 * *'
- cron: '0 12 * * MON'
workflow_dispatch:

permissions:
Expand All @@ -17,17 +17,24 @@ jobs:
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Configure git
run: |
# Setup for committing using built-in token. See https://github.com/actions/checkout#push-a-commit-using-the-built-in-token
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --global user.email "[email protected]"
git config --global user.name "Browserslist Update Action"
- name: Install pnpm
uses: pnpm/action-setup@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 18.12.1

- name: Update Browserslist database and create PR if applies
uses: c2corg/browserslist-update-action@v2
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
base_branch: master
commit_message: 'build: update Browserslist db'
title: 'build: update Browserslist db'
body: 'Auto-generated by [browserslist-update-action](https://github.com/c2corg/browserslist-update-action/)'
labels: 'dependencies, automerge'

0 comments on commit 14ab46b

Please sign in to comment.