Skip to content

Auto Yarn Upgrade

Auto Yarn Upgrade #6

Workflow file for this run

name: Auto Yarn Upgrade
on:
schedule:
# Runs at 12 am on the 1th day of every month
- cron: "0 0 1 * *"
workflow_dispatch: # This allows manual triggering
permissions:
contents: write
pull-requests: write
jobs:
upgrade:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
- name: Install and upgrade dependencies
run: |
yarn
yarn upgrade
- name: Commit changes
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git add .
git commit -m "upgrade dependencies" || echo "No changes to commit"
- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: upgrade dependencies
branch: auto-upgrade-branch
title: "Yarn Upgrade"
body: "This PR updates dependencies via `yarn upgrade`"