From c435ba2c764622445ee8d0f724425854de1deb05 Mon Sep 17 00:00:00 2001 From: Dulma Churchill Date: Mon, 7 Aug 2017 04:55:18 -0700 Subject: [PATCH] [linters] Add a reset option for linters-def-folder Reviewed By: jvillard Differential Revision: D5573312 fbshipit-source-id: 9b69d40 --- infer/src/base/Config.ml | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/infer/src/base/Config.ml b/infer/src/base/Config.ml index 9bc87a0aa..e1cd056e9 100644 --- a/infer/src/base/Config.ml +++ b/infer/src/base/Config.ml @@ -1237,9 +1237,16 @@ and linters_def_file = ~meta:"file" "Specify the file containing linters definition (e.g. 'linters.al')" and linters_def_folder = - CLOpt.mk_path_list ~default:[] ~long:"linters-def-folder" - ~in_help:CLOpt.([(Capture, manual_clang_linters)]) - ~meta:"dir" "Specify the folder containing linters files with extension .al" + let linters_def_folder = + CLOpt.mk_path_list ~default:[] ~long:"linters-def-folder" + ~in_help:CLOpt.([(Capture, manual_clang_linters)]) + ~meta:"dir" "Specify the folder containing linters files with extension .al" + in + let _ = + CLOpt.mk_set linters_def_folder [] ~long:"reset-linters-def-folder" + "Reset the list of folders containing linters definitions to be empty (see $(b,linters-def-folder))." + in + linters_def_folder and linters_ignore_clang_failures = CLOpt.mk_bool ~long:"linters-ignore-clang-failures"