Add a ‘SkipFileList’ in config.ini to exclude the files not be scanned.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Hess Chen <hesheng.chen@intel.com>
Reviewed-by: YangX Li <yangx.li@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17705
6f19259b-4bc3-4df7-8a09-
765794883524
## @file\r
# This file is used to define checkpoints used by ECC tool\r
#\r
-# Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2008 - 2015, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
Dirnames.append(Dirname)\r
if IgnoredPattern.match(Dirpath.upper()):\r
continue\r
+ for f in Filenames[:]:\r
+ if f.lower() in EccGlobalData.gConfig.SkipFileList:\r
+ Filenames.remove(f)\r
yield (Dirpath, Dirnames, Filenames)\r
\r
# Check whether return type exists and in the first line\r
## @file\r
# This file is used to define class Configuration\r
#\r
-# Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2008 - 2015, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
\r
# The directory listed here will not be parsed, split with ','\r
self.SkipDirList = []\r
+ \r
+ # The file listed here will not be parsed, split with ','\r
+ self.SkipFileList = []\r
\r
# A list for binary file ext name\r
self.BinaryExtList = []\r
continue\r
if List[0] == 'SkipDirList':\r
List[1] = GetSplitValueList(List[1], TAB_COMMA_SPLIT)\r
+ if List[0] == 'SkipFileList':\r
+ List[1] = GetSplitValueList(List[1], TAB_COMMA_SPLIT)\r
if List[0] == 'BinaryExtList':\r
List[1] = GetSplitValueList(List[1], TAB_COMMA_SPLIT)\r
self.__dict__[List[0]] = List[1]\r
## @file\r
# This file is used to be the c coding style checking of ECC tool\r
#\r
-# Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2009 - 2015, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
dirnames.append(Dirname)\r
\r
for f in filenames:\r
+ if f.lower() in EccGlobalData.gConfig.SkipFileList:\r
+ continue\r
collector = None\r
FullName = os.path.normpath(os.path.join(dirpath, f))\r
model = DataClass.MODEL_FILE_OTHERS\r