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

Unified Diff: remoting/tools/verify_resources.py

Issue 18323017: Localized Chromoting Host on Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 7 years, 5 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
Index: remoting/tools/verify_resources.py
diff --git a/remoting/tools/verify_resources.py b/remoting/tools/verify_resources.py
index 045f95de5b77b90ffb63f7593b8062c2597ec761..4ffd494ceb922098d2e29e5e0658b6e52bb58034 100755
--- a/remoting/tools/verify_resources.py
+++ b/remoting/tools/verify_resources.py
@@ -72,6 +72,10 @@ def ExtractTagFromLine(file_type, line):
# Manifest style
m = re.search('__MSG_(.*)__', line)
if m: return m.group(1)
+ elif file_type == 'jinja2':
+ # Jinja2 template file
+ m = re.search('\{\%\s+trans\s+\%\}([A-Z0-9_]+)\{\%\s+endtrans\s+\%\}', line)
+ if m: return m.group(1)
return None
@@ -85,7 +89,7 @@ def VerifyFile(filename, messages, used_tags):
base_name, extension = os.path.splitext(filename)
extension = extension[1:]
- if extension not in ['js', 'cc', 'html', 'json']:
+ if extension not in ['js', 'cc', 'html', 'json', 'jinja2']:
raise Exception("Unknown file type: %s" % extension)
result = True

Powered by Google App Engine
This is Rietveld 408576698