Skip to content

Commit dd7f65e

Browse files
committed
Add exit error code for no analyzers found in CLI
1 parent 110b237 commit dd7f65e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/FSharp.Analyzers.Cli/Program.fs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ open FSharp.Analyzers.Cli.CustomLogging
1818

1919
type ExitErrorCodes =
2020
| Success = 0
21+
| NoAnalyzersFound = -1
2122
| AnalyzerFoundError = -2
2223
| FailedAssemblyLoading = -3
2324
| AnalysisAborted = -4
@@ -810,7 +811,7 @@ let main argv =
810811
|> Some
811812

812813
match results with
813-
| None -> -1
814+
| None -> int ExitErrorCodes.NoAnalyzersFound
814815
| Some results ->
815816
let results, hasError =
816817
match Result.allOkOrError results with

0 commit comments

Comments
 (0)