name: Update Selenium Atoms on: workflow_dispatch: inputs: selenium_branch: description: Selenium branch/ref to build atoms from (upstream default is trunk) required: true default: trunk selenium_github: description: Selenium repository to clone required: true default: https://github.com/SeleniumHQ/selenium.git permissions: contents: write pull-requests: write jobs: update-atoms: runs-on: ubuntu-latest steps: - uses: actions/checkout@v7 - uses: actions/setup-node@v7 with: node-version: lts/* - uses: bazelbuild/setup-bazelisk@v3 - run: npm install --no-package-lock name: Install dependencies - run: npm run build:atoms name: Build Selenium atoms env: SELENIUM_BRANCH: ${{ inputs.selenium_branch }} SELENIUM_GITHUB: ${{ inputs.selenium_github }} - name: Create pull request id: cpr uses: peter-evans/create-pull-request@v8 with: token: ${{ secrets.GITHUB_TOKEN }} branch: chore/update-selenium-atoms delete-branch: true commit-message: "chore(atoms): update Selenium atoms from ${{ inputs.selenium_branch }}" title: "chore(atoms): update Selenium atoms from ${{ inputs.selenium_branch }}" body: | Automated atoms refresh from `${{ inputs.selenium_github }}` at `${{ inputs.selenium_branch }}`. This PR is generated by the manual `Update Selenium Atoms` workflow. add-paths: | atoms/** - name: Report result run: | if [ -n "${{ steps.cpr.outputs.pull-request-url }}" ]; then echo "Created PR: ${{ steps.cpr.outputs.pull-request-url }}" else echo "No atom changes detected. PR was not created." fi