Skip to content

Commit

Permalink
Ensure pages in en/ use "lang: en"
Browse files Browse the repository at this point in the history
  • Loading branch information
harding committed Aug 22, 2015
1 parent 6c14fb7 commit d0506fb
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ endif
pre-build-tests-fast: check-for-non-ascii-urls check-for-wrong-filename-assignments \
check-for-missing-rpc-summaries \
check-for-missing-copyright-licenses \
check-bundle
check-bundle \
check-for-english-in-en-dir

## Post-build tests which, aggregated together, take less than 10 seconds to run on a typical PC
post-build-tests-fast: check-for-build-errors ensure-each-svg-has-a-png check-for-liquid-errors \
Expand Down Expand Up @@ -273,3 +274,7 @@ check-for-subheading-anchors:
check-for-javascript-in-svgs:
## Security check: don't allow any SVGs that contain Javascript.
$S find _site/ -name '*.svg' | xargs grep '<script' | eval $(ERROR_ON_OUTPUT)

check-for-english-in-en-dir:
## All pages must have page.lang set to work properly with the site templates
$S grep -rl -- '---' en/ | xargs grep -L '^[^#]*lang: en' | eval $(ERROR_ON_OUTPUT)
2 changes: 2 additions & 0 deletions en/rss/alerts.rss
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
# This file is licensed under the MIT License (MIT) available on
# http://opensource.org/licenses/MIT.

lang: en
---
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
Expand Down
1 change: 1 addition & 0 deletions en/rss/blog.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# http://opensource.org/licenses/MIT.

layout: null
lang: en
---
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
Expand Down
2 changes: 2 additions & 0 deletions en/rss/events.rss
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
# This file is licensed under the MIT License (MIT) available on
# http://opensource.org/licenses/MIT.

lang: en
---
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
Expand Down
2 changes: 2 additions & 0 deletions en/rss/releases.rss
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
# This file is licensed under the MIT License (MIT) available on
# http://opensource.org/licenses/MIT.

lang: en
---
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
Expand Down

0 comments on commit d0506fb

Please sign in to comment.