File tree Expand file tree Collapse file tree 2 files changed +15
-2
lines changed
Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change @@ -8,10 +8,15 @@ This GitHub Action validates if an Xcode project file is sorted.
88
99** Required** The path to the Xcode project file.
1010
11+ ### ` report-warnings-as-error `
12+
13+ ** Optional** Report warnings as errors. Defaults to ` false ` .
14+
1115## Example usage
1216
1317``` yaml
1418uses : nthState/ValidateXcodeProjectSorted
1519with :
1620 project-path : ' ./ios/App.xcodeproj'
21+ report-warnings-as-error : true
1722` ` `
Original file line number Diff line number Diff line change 44 project-path :
55 description : ' Path to the Xcode project file'
66 required : true
7+ report-warnings-as-error :
8+ description : ' Report warnings as errors'
9+ required : false
10+ default : false
711runs :
812 using : ' composite'
913 steps :
1822 perl ./scripts/sort-xcode-project-file.pl "${{ inputs['project-path'] }}"
1923
2024 if ! [ -z "$(git status --porcelain | grep -e pbxproj$)" ]; then
21- echo "Project file is not sorted, this may make it harder to merge"
22- exit 1
25+ if [ "${{ inputs['report-warnings-as-error'] }}" = "true" ]; then
26+ echo "Project file is not sorted, this may make it harder to merge"
27+ exit 1
28+ else
29+ echo "::warning::Project file is not sorted, this may make it harder to merge"
30+ fi
2331 fi
You can’t perform that action at this time.
0 commit comments