forked from GrantBirki/json-yaml-validate
-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
49 lines (49 loc) · 1.98 KB
/
action.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
48
49
name: "json-yaml-validate"
description: "A GitHub Action to quickly validate JSON and YAML files in a repository"
author: "Grant Birkinbine"
branding:
icon: "check"
color: "green"
inputs:
github_token:
description: The GitHub token used to create an authenticated client - Provided for you by default!
default: ${{ github.token }}
required: false
mode:
description: The mode to run the action in "warn" or "fail" - Default is "fail"
required: false
default: "fail"
comment:
description: Whether or not to comment on a PR with the validation results - "true" or "false" - Default is "false"
required: false
default: "false"
base_dir:
description: The base directory to search for JSON and YAML files (e.g. ./src) - Default is "." which searches the entire repository
required: false
default: "."
schema_dir:
description: The full path to the JSON schema file (e.g. ./schemas/schema.json) - Default is "" which doesn't enforce a strict schema
required: true
default: ""
schema_name:
description: Name of the root schema
required: true
default: ""
exclude_file:
description: The full path to a file in the repository where this Action is running that contains a list of '.gitignore'-style patterns to exclude files from validation (e.g. ./exclude.txt)
required: false
default: ""
use_gitignore:
description: Whetheror not to use the .gitignore file in the root of the repository to exclude files from validation - "true" or "false" - Default is "true"
required: true
default: "true"
git_ignore_path:
description: The full path to the .gitignore file to use if use_gitignore is set to "true" (e.g. ./src/.gitignore) - Default is ".gitignore" which uses the .gitignore file in the root of the repository
required: false
default: ".gitignore"
outputs:
success:
description: Whether or not the validation was successful for all files - "true" or "false"
runs:
using: "node20"
main: "dist/index.js"