4 from common.header_checker import HeaderChecker
6 #--------------------------------------------------------------------------------------------------
8 #--------------------------------------------------------------------------------------------------
9 KERNEL_IGNORED_EXTENSIONS = [
32 KERNEL_IGNORED_PATTERNS = [
38 ' * FreeRTOS Kernel V10.4.2\n',
39 ' * Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.\n',
41 ' * Permission is hereby granted, free of charge, to any person obtaining a copy of\n',
42 ' * this software and associated documentation files (the "Software"), to deal in\n',
43 ' * the Software without restriction, including without limitation the rights to\n',
44 ' * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of\n',
45 ' * the Software, and to permit persons to whom the Software is furnished to do so,\n',
46 ' * subject to the following conditions:\n',
48 ' * The above copyright notice and this permission notice shall be included in all\n',
49 ' * copies or substantial portions of the Software.\n',
51 ' * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n',
52 ' * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS\n',
53 ' * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR\n',
54 ' * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER\n',
55 ' * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\n',
56 ' * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n',
58 ' * https://www.FreeRTOS.org\n',
59 ' * https://github.com/FreeRTOS\n',
66 parser = HeaderChecker.configArgParser()
67 args = parser.parse_args()
69 # Configure the checks then run
70 checker = HeaderChecker(KERNEL_HEADER)
71 checker.ignoreExtension(*KERNEL_IGNORED_EXTENSIONS)
72 checker.ignorePattern(*KERNEL_IGNORED_PATTERNS)
73 checker.ignoreFile(os.path.split(__file__)[-1])
75 return checker.processArgs(args)
77 if __name__ == '__main__':