From 84d4f62abfa8cf2d0abd39c5fcacd20b6fbe3f65 Mon Sep 17 00:00:00 2001 From: Tim Abbott Date: Thu, 9 Mar 2017 00:24:21 -0800 Subject: [PATCH] lint: Exclude Acme placeholders from translations. These strings represented a small waste of time for our translators. --- static/templates/settings/realm-domains-modal.handlebars | 2 +- templates/zerver/register.html | 4 ++-- tools/lint-all | 4 ++++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/static/templates/settings/realm-domains-modal.handlebars b/static/templates/settings/realm-domains-modal.handlebars index 0147f30ead..992b4440ef 100644 --- a/static/templates/settings/realm-domains-modal.handlebars +++ b/static/templates/settings/realm-domains-modal.handlebars @@ -14,7 +14,7 @@ - + diff --git a/templates/zerver/register.html b/templates/zerver/register.html index 5d4eb33069..228cc8d5a7 100644 --- a/templates/zerver/register.html +++ b/templates/zerver/register.html @@ -78,7 +78,7 @@ Form is validated both client-side using jquery-validate (see signup.js) and ser
{% if form.realm_name.errors %} @@ -101,7 +101,7 @@ Form is validated both client-side using jquery-validate (see signup.js) and ser
{% if realms_have_subdomains %} diff --git a/tools/lint-all b/tools/lint-all index bfed6431e0..79acc747cf 100755 --- a/tools/lint-all +++ b/tools/lint-all @@ -460,6 +460,10 @@ def build_custom_checkers(by_lang): html_rules = whitespace_rules + prose_style_rules + [ {'pattern': 'placeholder="[^{]', 'description': "`placeholder` value should be translatable.", + 'exclude_line': [('templates/zerver/register.html', 'placeholder="acme"'), + ('templates/zerver/register.html', 'placeholder="Acme"'), + ('static/templates/settings/realm-domains-modal.handlebars', + '')], 'exclude': set(["static/templates/settings/emoji-settings-admin.handlebars", "static/templates/settings/realm-filter-settings-admin.handlebars", "static/templates/settings/bot-settings.handlebars"])},