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

Unified Diff: tools/licenses.py

Issue 10816041: Add a tool to check license compatibility with Android (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed nit Created 8 years, 4 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 | « chrome/version.h.in ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/licenses.py
diff --git a/tools/licenses.py b/tools/licenses.py
index d67c08226518b7b8811a58ec43adfc2087fffcb2..d4140f8f3d9d326a421913031e2025b71efe497e 100755
--- a/tools/licenses.py
+++ b/tools/licenses.py
@@ -310,13 +310,13 @@ def ContainsFiles(path):
return False
-def FindThirdPartyDirs():
+def FindThirdPartyDirs(prune_paths):
"""Find all third_party directories underneath the current directory."""
third_party_dirs = []
for path, dirs, files in os.walk('.'):
path = path[len('./'):] # Pretty up the path.
- if path in PRUNE_PATHS:
+ if path in prune_paths:
dirs[:] = []
continue
@@ -331,7 +331,7 @@ def FindThirdPartyDirs():
# Add all subdirectories that are not marked for skipping.
for dir in dirs:
dirpath = os.path.join(path, dir)
- if dirpath not in PRUNE_PATHS:
+ if dirpath not in prune_paths:
third_party_dirs.append(dirpath)
# Don't recurse into any subdirs from here.
@@ -353,7 +353,7 @@ def FindThirdPartyDirs():
def ScanThirdPartyDirs():
"""Scan a list of directories and report on any problems we find."""
- third_party_dirs = FindThirdPartyDirs()
+ third_party_dirs = FindThirdPartyDirs(PRUNE_PATHS)
errors = []
for path in sorted(third_party_dirs):
@@ -381,7 +381,7 @@ def GenerateCredits():
template = template.replace('{{%s}}' % key, val)
return template
- third_party_dirs = FindThirdPartyDirs()
+ third_party_dirs = FindThirdPartyDirs(PRUNE_PATHS)
entry_template = open('chrome/browser/resources/about_credits_entry.tmpl',
'rb').read()
« no previous file with comments | « chrome/version.h.in ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698