Skip to content

Update dprint plugins #27

Update dprint plugins

Update dprint plugins #27

name: Update dprint plugins
on:
push:
branches: ['main']
paths:
- '.github/workflows/dprint-update-plugin.yml'
schedule:
# Run at 17:00 UTC every Monday
- cron: '0 17 * * 1'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
permissions:
contents: write
pull-requests: write
# Allow one concurrent dprint updater
concurrency:
group: 'update-dprint'
cancel-in-progress: true
jobs:
update:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- id: update-dprint-plugins
uses: kachick/action-update-dprint-plugins@v1.0.0
with:
base-branch: 'main'
# Enable `Allow auto-merge` in your repository settings if you need following steps
- name: Merge sent PR
# Merge if `dprint fmt` does not make any diff even after updating plugins
if: ${{ steps.update-dprint-plugins.outputs.pr_url != '' && steps.update-dprint-plugins.outputs.fmt == 'false' }}
run: gh pr merge --auto --squash --delete-branch "${{ steps.update-dprint-plugins.outputs.pr_url }}"
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'