summaryrefslogtreecommitdiffstats
path: root/tools/licenses.py
diff options
context:
space:
mode:
authorevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-23 17:18:14 +0000
committerevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-23 17:18:14 +0000
commit7511d4c0964f65715e18019ae1614c3c53275548 (patch)
tree97713b10ec98bac8dd867d1041b7af89aabbcb42 /tools/licenses.py
parent049529c6d759733653d7f86d3d89ca941270cc69 (diff)
downloadchromium_src-7511d4c0964f65715e18019ae1614c3c53275548.zip
chromium_src-7511d4c0964f65715e18019ae1614c3c53275548.tar.gz
chromium_src-7511d4c0964f65715e18019ae1614c3c53275548.tar.bz2
Check in a new generated about:credits.
We still don't cover every library, but this is better than what we have. Modify the credits-generator to only warn about missing entries. BUG=39240 Review URL: http://codereview.chromium.org/1719011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@45455 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/licenses.py')
-rwxr-xr-xtools/licenses.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/tools/licenses.py b/tools/licenses.py
index ff548a3..7040c5b 100755
--- a/tools/licenses.py
+++ b/tools/licenses.py
@@ -199,7 +199,12 @@ def GenerateCredits():
'rb').read()
entries = []
for path in sorted(third_party_dirs):
- metadata = ParseDir(path)
+ try:
+ metadata = ParseDir(path)
+ except LicenseError:
+ print >>sys.stderr, ("WARNING: licensing info for " + path +
+ " is incomplete, skipping.")
+ continue
env = {
'name': metadata['Name'],
'url': metadata['URL'],
@@ -209,6 +214,7 @@ def GenerateCredits():
file_template = open('chrome/browser/resources/about_credits.tmpl',
'rb').read()
+ print "<!-- Generated by licenses.py; do not edit. -->"
print EvaluateTemplate(file_template, {'entries': '\n'.join(entries)},
escape=False)