-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaction.yml
More file actions
44 lines (40 loc) · 1.49 KB
/
action.yml
File metadata and controls
44 lines (40 loc) · 1.49 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
# This workflow ensures all code being pushed to your repository is formatted.
# Feel free to change it so it happens on pulls! Look over Github's documentation on actions if you're confused
name: C# Unity Auto Formatting
description: Auto formatter to format C# code (CS, CSharp). Check style or format it. In separate commits or squash them into one.
author: SilvaUnCompte
branding:
icon: 'activity'
color: 'red'
# This is where we gather the inputs for the action
inputs:
path:
description: 'The path to the scripts you want formatted.'
required: true
default: './Assets/Scripts/'
check_only:
description: 'Perform only a style check (true) or format it (false).'
required: false
default: 'false' # true|false
diff_check:
description: 'Check only the files changed in the commit or PR (true) or all files in the path (false).'
required: false
default: 'false' # true|false
check_severity:
description: 'Set the severity of style checks, either "warn" or "error".'
required: false
default: 'error' # warn|error
squash_commit:
description: 'How the action manage the commit, edit the previous one (true) or create a new one (false).'
required: false
default: 'false' # true|false
# The inputs above are then fed into a the Dockerfile
runs:
using: 'docker'
image: 'Dockerfile'
args:
- ${{ inputs.path }}
- ${{ inputs.check_only }}
- ${{ inputs.diff_check }}
- ${{ inputs.check_severity }}
- ${{ inputs.squash_commit }}