-
Notifications
You must be signed in to change notification settings - Fork 1
47 lines (38 loc) · 1.2 KB
/
update-pre-commit.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Update pre-commit hooks
on:
schedule:
# Twice a month, on the 15th and the 29th
- cron: "23 17 15,29 * *"
jobs:
update:
runs-on: ubuntu-latest
steps:
- name: Checkout current repository
uses: actions/checkout@v2
- name: Checkout pre-commit-tools repository
uses: actions/checkout@v2
with:
repository: maxpatiiuk/pre-commit-tools
path: ./pre-commit-tools
- name: Install Node.JS
uses: actions/setup-node@v2
with:
node-version: 17.3.0
cache: npm
- name: Install dependencies
working-directory: ./pre-commit-tools
run: npm install
- name: Update the hooks
working-directory: ./pre-commit-tools/pre-commit-tools
run: node updateHooks.js ../../git/.pre-commit-config.yaml
- name: Commit changes
uses: EndBug/[email protected]
with:
add: git/.pre-commit-config.yaml
branch: main
committer_name: Max Patiiuk
committer_email: [email protected]
default_author: github_actions
message: Update pre-commit hooks
pathspec_error_handling: exitImmediately
push: true