From b2996e775fb88ce50c48c7298754a9243cd083b8 Mon Sep 17 00:00:00 2001 From: Federico Brigante Date: Mon, 19 Aug 2024 23:55:59 +0700 Subject: [PATCH] Auto-commit instead --- .github/workflows/ci.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0f15846..b3589ad 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,11 +14,17 @@ jobs: run: npx xo Sort: runs-on: ubuntu-latest + permissions: + contents: write steps: - uses: actions/checkout@v4 - - run: jq sort reserved-names.json > sort && mv sort reserved-names.json - name: Sort reserved-names.json - - run: git diff --exit-code + - name: Sort reserved-names.json + run: jq sort reserved-names.json > sort && mv sort reserved-names.json + - name: Commit sorted file if necessary + uses: stefanzweifel/git-auto-commit-action@v5 + with: + commit_message: Sort reserved-names.json + Test: runs-on: ubuntu-latest steps: