forked from kOchirasu/Maple2.File
-
Notifications
You must be signed in to change notification settings - Fork 7
33 lines (26 loc) · 805 Bytes
/
format.yml
File metadata and controls
33 lines (26 loc) · 805 Bytes
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
name: Format
on:
pull_request:
branches: ["master"]
permissions:
contents: write
jobs:
format:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.head_ref }}
token: ${{ secrets.GITHUB_TOKEN }}
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9
- name: Run dotnet format
run: dotnet format whitespace
- name: Commit changes
if: github.event_name != 'pull_request' || github.repository == github.event.pull_request.head.repo.full_name
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "style: auto-format whitespace"