diff options
author | rmistry <rmistry@google.com> | 2014-08-26 14:00:54 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-08-26 14:00:55 -0700 |
commit | 9407eceb2784dd13c135f8f266ffbeb1ffe5fd48 (patch) | |
tree | b63942a1afa99fefb8431a82071c848135ba0226 /PRESUBMIT.py | |
parent | 50119fa861eaebe9f32e7131d7655f1471948cf9 (diff) |
PRESUBMIT should only check owners for the top level include directory
BUG=skia:1846
R=borenet@google.com
Author: rmistry@google.com
Review URL: https://codereview.chromium.org/511503002
Diffstat (limited to 'PRESUBMIT.py')
-rw-r--r-- | PRESUBMIT.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/PRESUBMIT.py b/PRESUBMIT.py index 726983027c..61fa2d6f92 100644 --- a/PRESUBMIT.py +++ b/PRESUBMIT.py @@ -189,11 +189,12 @@ def _CheckLGTMsForPublicAPI(input_api, output_api): """ results = [] requires_owner_check = False - for affected_svn_file in input_api.AffectedFiles(): - affected_file_path = affected_svn_file.AbsoluteLocalPath() + for affected_file in input_api.AffectedFiles(): + affected_file_path = affected_file.LocalPath() file_path, file_ext = os.path.splitext(affected_file_path) - # We only care about files that end in .h and are under the include dir. - if file_ext == '.h' and 'include' in file_path.split(os.path.sep): + # We only care about files that end in .h and are under the top-level + # include dir. + if file_ext == '.h' and 'include' == file_path.split(os.path.sep)[0]: requires_owner_check = True if not requires_owner_check: |