Skip to content

Update contributors #64

Update contributors

Update contributors #64

name: Update contributors
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * 2,5"
permissions:
actions: write
contents: write
pull-requests: write
jobs:
update-contributors:
name: Update contributors
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
- name: Setup node
uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # v4.0.4
with:
node-version-file: ".node-version"
- name: Update contributors
run: node scripts/update-contributors.js --token=${{ secrets.GITHUB_TOKEN }}
- name: Create pull request
id: create-pull-request
uses: peter-evans/create-pull-request@c5a7806660adbe173f04e3e038b0ccdcd758773c # v6.1.0
with:
branch: chore/update-contributors
author: "github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>"
title: "chore(ci): update contributors"
commit-message: "chore(ci): update contributors"
body: ""
labels: CI-Contributors
- name: Auto merge
if: ${{ steps.create-pull-request.outputs.pull-request-operation != 'closed' && steps.create-pull-request.outputs.pull-request-number != '' }}
run: gh pr merge --squash --auto --delete-branch ${{ steps.create-pull-request.outputs.pull-request-number }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}