From 97ced7fb077f8995685a76919a9ca5f6bb2f04ec Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Wed, 22 Mar 2017 13:07:52 -0700 Subject: [PATCH] Move cpplint config to CPPLINT.cfg file --- brightray/CPPLINT.cfg | 2 ++ brightray/script/cpplint | 12 +----------- 2 files changed, 3 insertions(+), 11 deletions(-) create mode 100644 brightray/CPPLINT.cfg diff --git a/brightray/CPPLINT.cfg b/brightray/CPPLINT.cfg new file mode 100644 index 000000000000..3ca9f82ea820 --- /dev/null +++ b/brightray/CPPLINT.cfg @@ -0,0 +1,2 @@ +filter=-build/header_guard,-build/include_what_you_use,-legal/copyright,-runtime/references +linelength=100 diff --git a/brightray/script/cpplint b/brightray/script/cpplint index f3a871d6e3d6..8956857a6791 100755 --- a/brightray/script/cpplint +++ b/brightray/script/cpplint @@ -8,21 +8,11 @@ import sys SOURCE_ROOT = os.path.abspath(os.path.dirname(os.path.dirname(__file__))) CPPLINT = os.path.join(SOURCE_ROOT, 'vendor', 'libchromiumcontent', 'vendor', 'depot_tools', 'cpplint.py') -LINE_LENGTH = 100 IGNORED_FILES = [ os.path.join('browser', 'mac', 'bry_inspectable_web_contents_view.h'), ] -FILTERS = [ - '-build/header_guard', - '-build/include_what_you_use', - '-legal/copyright', - # cpplint doesn't like the BOOL& parameters that ui::WindowImpl uses. - '-runtime/references', -] - - def main(): os.chdir(SOURCE_ROOT) files = list_files(['browser', 'common'], @@ -41,7 +31,7 @@ def list_files(directories, filters): def cpplint(files): - return subprocess.call([sys.executable, CPPLINT, '--linelength=%d' % LINE_LENGTH, '--filter=' + ','.join(FILTERS)] + list(files)) + return subprocess.call([sys.executable, CPPLINT] + list(files)) if __name__ == '__main__':