ChromeDriver Version Bump #1335
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ChromeDriver Version Bump | |
on: | |
schedule: | |
- cron: "0 0 * * *" | |
workflow_dispatch: | |
env: | |
API_URL: https://googlechromelabs.github.io/chrome-for-testing/last-known-good-versions.json | |
CD_VERSIONS_MAPPING: config/mapping.json | |
jobs: | |
bump_cd_version: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: lts/* | |
- run: npm install | |
- id: release_check | |
run: | | |
export latest_release=$(curl -sf ${{ env.API_URL }} | jq .channels.Stable.version | tr -d '"' ) | |
export did_update=$(node "scripts/update_versions_mapping.js" "$latest_release" "${{ env.CD_VERSIONS_MAPPING }}") | |
echo "did_update=${did_update}" >> "$GITHUB_OUTPUT" | |
echo "cd_release=${latest_release}" >> "$GITHUB_OUTPUT" | |
- name: pull-request | |
if: steps.release_check.outputs.did_update == '1' | |
uses: peter-evans/create-pull-request@v3 | |
with: | |
branch: ${{ steps.release_check.outputs.cd_release }} | |
title: "chore: ChromeDriver Bump to v${{ steps.release_check.outputs.cd_release }}" | |
body: "" |