-
-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (45 loc) · 1.35 KB
/
pre-commit-autoupdate.yml
File metadata and controls
54 lines (45 loc) · 1.35 KB
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
48
49
50
51
52
53
54
name: "Pre-commit autoupdate"
on:
schedule:
- cron: '0 6 1 * *'
workflow_dispatch:
jobs:
autoupdate:
name: autoupdate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6.0.2
with:
ref: main
- name: Set up Python
uses: actions/setup-python@v6.2.0
with:
python-version-file: '.python-version'
- name: Install system deps
shell: bash
run: |
pip install poetry
pip install poetry-plugin-export
poetry config virtualenvs.in-project true
poetry install --no-root --only dev --sync
- name: Install galaxy deps
shell: bash
run: |
poetry run ansible-galaxy install -r requirements.yml
- name: Run autoupdate
run: poetry run pre-commit autoupdate
- name: Run pre-commit
run: poetry run pre-commit run --all-files
- uses: peter-evans/create-pull-request@v8.1.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: chore-update-pre-commit-hooks
title: Update pre-commit hooks
commit-message: "Update pre-commit hooks"
body: |
# Update pre-commit hooks
- Update pre-commit hooks to the latest version.
delete-branch: true
labels: |
dependencies
python