Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(458)

Unified Diff: presubmit_canned_checks.py

Issue 10005029: Ensure .mk files aren't included in the tab character check. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools/
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: presubmit_canned_checks.py
===================================================================
--- presubmit_canned_checks.py (revision 131044)
+++ presubmit_canned_checks.py (working copy)
@@ -271,8 +271,9 @@
# It's the default filter.
source_file_filter = input_api.FilterSourceFile
def filter_more(affected_file):
- return (not input_api.os_path.basename(affected_file.LocalPath()) in
- ('Makefile', 'makefile') and
+ basename = input_api.os_path.basename(affected_file.LocalPath())
+ return (not (basename in ('Makefile', 'makefile') or
+ basename.endswith('.mk')) and
source_file_filter(affected_file))
tabs = _FindNewViolationsOfRule(lambda _, line : '\t' not in line,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698