Skip to content

Update the pinned browsers #79

Update the pinned browsers

Update the pinned browsers #79

# This workflow will update the pinned browsers
name: 'Update the pinned browsers'
permissions: read-all
on:
schedule:
# Run everyday at: https://crontab.guru/#0_6_*_*_*.
- cron: '0 6 * * *'
workflow_dispatch:
jobs:
update-chrome:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Node.js
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
cache: npm
node-version-file: '.nvmrc'
- uses: google/wireit@f21db1f3a6a4db31f42787a958cf2a18308effed # setup-github-actions-caching/v2.0.3
- name: Install npm dependencies
run: npm ci
- name: Build Puppeteer
run: npm run build -w puppeteer
- name: Update Chrome to latest stable version
id: update
run: |
node tools/update_browser_revision.mjs
env:
BROWSER_TO_UPDATE: 'chrome'
- name: Create Pull Request
if: ${{ steps.update.outputs.commit }}
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8
with:
token: ${{ secrets.BROWSER_AUTOMATION_BOT_TOKEN }}
branch: browser-automation-bot/update-browser-version-chrome
delete-branch: true
committer: Browser Automation Bot <[email protected]>
author: Browser Automation Bot <[email protected]>
commit-message: ${{ steps.update.outputs.commit }}
title: ${{ steps.update.outputs.commit }}
body: 'Automatically generated by https://github.com/puppeteer/puppeteer/blob/main/.github/workflows/update-browser-pins.yml'
push-to-fork: browser-automation-bot/puppeteer
update-firefox:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Node.js
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
cache: npm
node-version-file: '.nvmrc'
- uses: google/wireit@f21db1f3a6a4db31f42787a958cf2a18308effed # setup-github-actions-caching/v2.0.3
- name: Install npm dependencies
run: npm ci
- name: Build Puppeteer
run: npm run build -w puppeteer
- name: Update Firefox to latest stable version
id: update
run: |
node tools/update_browser_revision.mjs
env:
BROWSER_TO_UPDATE: 'firefox'
- name: Create Pull Request
if: ${{ steps.update.outputs.commit }}
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8
with:
token: ${{ secrets.BROWSER_AUTOMATION_BOT_TOKEN }}
branch: browser-automation-bot/update-browser-version-firefox
delete-branch: true
committer: Browser Automation Bot <[email protected]>
author: Browser Automation Bot <[email protected]>
commit-message: ${{ steps.update.outputs.commit }}
title: ${{ steps.update.outputs.commit }}
body: 'Automatically generated by https://github.com/puppeteer/puppeteer/blob/main/.github/workflows/update-browser-pins.yml'
push-to-fork: browser-automation-bot/puppeteer