generated from credfeto/cs-template
-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (37 loc) · 1.15 KB
/
reformat-yaml.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
name: "Standardise: YAML format"
on:
push:
branches-ignore:
- "release/*"
- "hotfix/*"
paths:
- '**.yml'
- '**.yaml'
concurrency:
group: ${{github.workflow}}-${{github.ref}}
cancel-in-progress: true
permissions:
contents: write
jobs:
standardise-yaml-files:
if: |-
${{github.event.pull_request.draft == false
&& ( !startsWith(github.head_ref, 'release/')
&& !startsWith(github.head_ref, 'hotfix/') )
&& github.actor != 'dependabot[bot]'}}
runs-on: ubuntu-latest
steps:
- run: sudo chown -R "$USER:$USER" "$GITHUB_WORKSPACE"
- uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{secrets.SOURCE_PUSH_TOKEN}}
- uses: credfeto/[email protected]
- uses: stefanzweifel/[email protected]
with:
commit_message: "[Reformat] YAML Files to common format"
file_pattern: "*.yml"
commit_user_name: "fun-ymlfmt[bot]"
commit_user_email: "[email protected]"
commit_author: "fun-ymlfmt[bot] <[email protected]>"
skip_dirty_check: false