Skip to content

Commit

Permalink
pre-commit autoupdate CI (#4906)
Browse files Browse the repository at this point in the history
  • Loading branch information
keewis authored Feb 15, 2021
1 parent f3f0a14 commit aa5d918
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/ci-pre-commit-autoupdate.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: "pre-commit autoupdate CI"

on:
schedule:
- cron: "0 0 * * 0" # every Sunday at 00:00 UTC
workflow_dispatch:


jobs:
autoupdate:
name: 'pre-commit autoupdate'
runs-on: ubuntu-latest
if: github.repository == 'pydata/xarray'
steps:
- name: checkout
uses: actions/checkout@v2
- name: Cache pip and pre-commit
uses: actions/cache@v2
with:
path: |
~/.cache/pre-commit
~/.cache/pip
key: ${{ runner.os }}-pre-commit-autoupdate
- name: setup python
uses: actions/setup-python@v2
- name: upgrade pip
run: python -m pip install --upgrade pip
- name: install pre-commit
run: python -m pip install --upgrade pre-commit
- name: version info
run: python -m pip list
- name: autoupdate
uses: technote-space/create-pr-action@837dbe469b39f08d416889369a52e2a993625c84
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
EXECUTE_COMMANDS: |
python -m pre_commit autoupdate
COMMIT_MESSAGE: 'pre-commit: autoupdate hook versions'
PR_TITLE: 'pre-commit: autoupdate hook versions'
PR_BRANCH_PREFIX: 'pre-commit/'
PR_BRANCH_NAME: 'autoupdate-${PR_ID}'

0 comments on commit aa5d918

Please sign in to comment.