[extensions-web] js: Remove trailing whitespace from generated templates



commit 106e4dd579a596d654a540dd8c7843e756d87a5d
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Tue Sep 25 23:40:36 2012 -0300

    js: Remove trailing whitespace from generated templates

 sweettooth/static/js/templates/build_templates.py |    2 +-
 sweettooth/static/js/templates/templatedata.js    |   18 +++++++++---------
 2 files changed, 10 insertions(+), 10 deletions(-)
---
diff --git a/sweettooth/static/js/templates/build_templates.py b/sweettooth/static/js/templates/build_templates.py
index 94165e2..8323885 100644
--- a/sweettooth/static/js/templates/build_templates.py
+++ b/sweettooth/static/js/templates/build_templates.py
@@ -27,7 +27,7 @@ def build_templates(directory):
 "use strict";
 
 define(%s);
-""" % (json.dumps(templates, sort_keys=True, indent=2),))
+""" % (json.dumps(templates, sort_keys=True, indent=2, separators=(',', ': ')),))
     f.close()
 
 if __name__ == "__main__":
diff --git a/sweettooth/static/js/templates/templatedata.js b/sweettooth/static/js/templates/templatedata.js
index a668fb8..5668038 100644
--- a/sweettooth/static/js/templates/templatedata.js
+++ b/sweettooth/static/js/templates/templatedata.js
@@ -2,14 +2,14 @@
 "use strict";
 
 define({
-  "extensions/comment": "<div class=\"comment\">\n  {{#is_extension_creator}}\n  <div class=\"extension-creator-badge\">Author</div>\n  {{/is_extension_creator}}\n  <img src=\"{{gravatar}}\" class=\"gravatar\">\n  <div class=\"rating-author\">\n    {{#has_rating}}\n      <div class=\"rating\" data-rating-value=\"{{rating}}\"></div> by\n    {{/has_rating}}\n    <a class=\"comment-author\" href=\"{{author.url}}\">{{author.username}}</a>\n    <p>{{comment}}</p>\n    <time datetime=\"{{date.timestamp}}Z\">{{date.standard}}</time>\n  </div>\n</div>", 
-  "extensions/comments_list": "{{#.}}\n  {{>extensions/comment}}\n  <hr>\n{{/.}}\n{{^.}}\n  <p>There are no comments. Be the first!</p>\n{{/.}}", 
-  "extensions/error_report_template": "What's wrong?\n\n\n\nWhat have you tried?\n\n\n\nAutomatically detected errors:\n\n{{#errors}}\n  {{.}}\n\n================\n{{/errors}}\n{{^errors}}\nGNOME Shell Extensions did not detect any errors with this extension.\n{{/errors}}\n\nVersion information:\n\n    Shell version: {{sv}}\n    Extension version: {{#ev}}{{ev}}{{/ev}}{{^ev}}Unknown{{/ev}}", 
-  "extensions/info": "<div class=\"extension\" data-uuid=\"{{uuid}}\">\n  {{>extensions/info_contents}}\n</div>", 
-  "extensions/info_contents": "<div class=\"switch\"></div>\n<div class=\"extra-buttons\">\n  <div class=\"upgrade-button\" title=\"Upgrade this extension\"></div>\n  <div class=\"configure-button\" title=\"Configure this extension\"></div>\n</div>\n<h3 class=\"extension-name\">\n  {{#link}}\n    <a href=\"{{link}}\" class=\"title-link\"> <img src=\"{{icon}}\" class=\"icon\"> {{name}} </a>\n  {{/link}}\n  {{^link}}\n  {{name}}\n  {{/link}}\n</h3>\n{{#creator}}\n  <span class=\"author\">by <a href=\"{{creator_url}}\"> {{creator}} </a></span>\n{{/creator}}\n<p class=\"description\">{{first_line_of_description}}</p>\n{{#want_uninstall}}\n  <button class=\"uninstall\" title=\"Uninstall\">Uninstall</button>\n{{/want_uninstall}}", 
-  "extensions/info_list": "<ul class=\"extensions\">\n{{#extensions}}\n  <li class=\"extension\" data-svm=\"{{shell_version_map}}\">\n    {{>extensions/info_contents}}\n  </li>\n{{/extensions}}\n</ul>", 
-  "extensions/uninstall": "You uninstalled <b>{{name}}</b>.", 
-  "messages/cannot_list_errors": "GNOME Shell Extensions cannot automatically detect any errors.", 
-  "messages/cannot_list_local": "GNOME Shell Extensions cannot list your installed extensions.", 
+  "extensions/comment": "<div class=\"comment\">\n  {{#is_extension_creator}}\n  <div class=\"extension-creator-badge\">Author</div>\n  {{/is_extension_creator}}\n  <img src=\"{{gravatar}}\" class=\"gravatar\">\n  <div class=\"rating-author\">\n    {{#has_rating}}\n      <div class=\"rating\" data-rating-value=\"{{rating}}\"></div> by\n    {{/has_rating}}\n    <a class=\"comment-author\" href=\"{{author.url}}\">{{author.username}}</a>\n    <p>{{comment}}</p>\n    <time datetime=\"{{date.timestamp}}Z\">{{date.standard}}</time>\n  </div>\n</div>",
+  "extensions/comments_list": "{{#.}}\n  {{>extensions/comment}}\n  <hr>\n{{/.}}\n{{^.}}\n  <p>There are no comments. Be the first!</p>\n{{/.}}",
+  "extensions/error_report_template": "What's wrong?\n\n\n\nWhat have you tried?\n\n\n\nAutomatically detected errors:\n\n{{#errors}}\n  {{.}}\n\n================\n{{/errors}}\n{{^errors}}\nGNOME Shell Extensions did not detect any errors with this extension.\n{{/errors}}\n\nVersion information:\n\n    Shell version: {{sv}}\n    Extension version: {{#ev}}{{ev}}{{/ev}}{{^ev}}Unknown{{/ev}}",
+  "extensions/info": "<div class=\"extension\" data-uuid=\"{{uuid}}\">\n  {{>extensions/info_contents}}\n</div>",
+  "extensions/info_contents": "<div class=\"switch\"></div>\n<div class=\"extra-buttons\">\n  <div class=\"upgrade-button\" title=\"Upgrade this extension\"></div>\n  <div class=\"configure-button\" title=\"Configure this extension\"></div>\n</div>\n<h3 class=\"extension-name\">\n  {{#link}}\n    <a href=\"{{link}}\" class=\"title-link\"> <img src=\"{{icon}}\" class=\"icon\"> {{name}} </a>\n  {{/link}}\n  {{^link}}\n  {{name}}\n  {{/link}}\n</h3>\n{{#creator}}\n  <span class=\"author\">by <a href=\"{{creator_url}}\"> {{creator}} </a></span>\n{{/creator}}\n<p class=\"description\">{{first_line_of_description}}</p>\n{{#want_uninstall}}\n  <button class=\"uninstall\" title=\"Uninstall\">Uninstall</button>\n{{/want_uninstall}}",
+  "extensions/info_list": "<ul class=\"extensions\">\n{{#extensions}}\n  <li class=\"extension\" data-svm=\"{{shell_version_map}}\">\n    {{>extensions/info_contents}}\n  </li>\n{{/extensions}}\n</ul>",
+  "extensions/uninstall": "You uninstalled <b>{{name}}</b>.",
+  "messages/cannot_list_errors": "GNOME Shell Extensions cannot automatically detect any errors.",
+  "messages/cannot_list_local": "GNOME Shell Extensions cannot list your installed extensions.",
   "messages/dummy_proxy": "You do not appear to have an up to date version of GNOME3. You won't be able to install extensions from here. See the <a href=\"about/#old-version\">about page</a> for more information."
 });



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]