Commit Graph

56 Commits

Author SHA1 Message Date
Ned Batchelder
1e8a0cb7e0 Tighten up the extraction I/O
We were writing the main file twice.  No need.
2014-01-24 16:18:43 -05:00
Ned Batchelder
2abd647375 Always add Plural metadata to dummy translations.
When this was conditional, we'd have plural info in some files, not in
others. Then we'd merge them, and msgcat would add wacky markers to
indicate the difference, and the metadata wouldn't parse.
2014-01-24 16:17:46 -05:00
Calen Pennington
58355f071f Merge pull request #2281 from cpennington/fix-i18n-execute
Use subprocess.STDOUT, rather than sys.STDOUT to rebind stderr
2014-01-24 03:48:23 -08:00
Ned Batchelder
9ea21dd9c7 i18n: extract and generate properly handle segments 2014-01-23 17:39:36 -05:00
Ned Batchelder
058569035f A few improvements to extract.
Use the configuration more, and we don't need to delete files we're
about to create.
2014-01-23 17:11:38 -05:00
Ned Batchelder
f76a5e174c I18n segmenting tool.
Messages can be segmented into different .po files based on the location
of their occurrences.  This is so Studio strings can go into different
.po files so we can direct Transifex workers to the LMS strings we
really need done.
2014-01-23 17:11:38 -05:00
Ned Batchelder
aa1ab5c792 Use yaml for a civilized config file. 2014-01-23 17:11:38 -05:00
Calen Pennington
c7d53b4219 Use subprocess.STDOUT, rather than sys.STDOUT to rebind stderr 2014-01-23 14:41:13 -05:00
Calen Pennington
cb77826a4d Merge pull request #2257 from cpennington/test-compiled-translations
Add tests of compiled translated strings, so that we can check them into the repo safely.
2014-01-23 07:22:24 -08:00
Calen Pennington
d70eb3aa6a Add a test that validates that the .po and .mo files match for all active languages 2014-01-22 14:51:35 -05:00
Calen Pennington
c7bf282111 Don't capture the output of i18n command execution 2014-01-22 14:51:34 -05:00
Sarina Canelake
8f3ba3271d Make test_validate into separate command-line script (i18n)
LMS-1963
2014-01-22 12:30:12 -05:00
Sarina Canelake
2b45ebc82f Change i18n contact address 2014-01-21 08:38:41 -05:00
Sarina Canelake
fffa4f36da Change i18n contact address 2014-01-20 16:01:45 -05:00
Ned Batchelder
cab1c04e5e Make i18n a real package. 2014-01-20 11:34:54 -05:00
Ned Batchelder
4e298a1abb Add an apostrophe to the Lorem text. 2014-01-10 14:35:17 -05:00
Ned Batchelder
c329270f43 Dont extract test_root strings 2014-01-10 07:18:17 -05:00
Ned Batchelder
af120fdf53 Better handling of plurals during .po validation
Now any of the plurals being missing will count as an Empty translation,
and for looking at tags, the two English strings and all the translated
strings are mooshed together.
2014-01-07 09:43:46 -05:00
Ned Batchelder
c459633534 Say a little about what's happening when pulling from transifex 2014-01-07 09:43:46 -05:00
Ned Batchelder
dd94af4bdb More validation of .po files: check message structure
The tests in test_validate.py now examine the messages to see that they
have the right structure.  The English and the translation should have
the same tags, the translation can't be blank, and it can't have any
Astral plane characters.
2014-01-07 09:43:46 -05:00
Ned Batchelder
9011e6e17f Fix plural handling, put teeth in msgfmt -c test. 2014-01-07 09:43:46 -05:00
Ned Batchelder
d8df97aa50 Use ddt to separate test cases into tests. 2014-01-07 09:43:46 -05:00
Ned Batchelder
209f8cc3db Lorem is now fancy, and HTML tags are recognized with single-quote attributes. 2014-01-07 09:43:46 -05:00
Ned Batchelder
6d5e13e245 Use the same marker everywhere for translator comments. 2014-01-07 09:43:46 -05:00
Ned Batchelder
550f15caea i18n tests run better: no subprocess output, and no duplication of tests. 2013-12-20 10:26:08 -05:00
Ned Batchelder
f1f76a9ad1 Dummy text has more accents, and properly ignored more non-text things. 2013-12-20 10:25:32 -05:00
Ned Batchelder
5e244b1c3b Minor style changes to the i18n directory. 2013-12-20 10:24:33 -05:00
David Baumgold
3d2ad59c51 Merge pull request #1907 from edx/db/whitespace-fixes
whitespace-only changes
2013-12-13 11:40:54 -08:00
David Baumgold
fb13bed947 Updating comments and docs for MITx -> edX transition 2013-12-10 13:21:18 -05:00
David Baumgold
28f22393bf whitespace-only changes 2013-12-10 11:45:49 -05:00
Sarina Canelake
bd8fce5a8a Change dummy locale to Esperanto 2013-11-19 10:28:02 -05:00
Adam Palay
3be155bd88 fix tests, remove zh_CN from config until we have support 2013-08-01 14:13:41 -04:00
Adam Palay
2b40462263 convert all datetime.now() to datetime.now(UTC) 2013-07-22 17:39:11 -04:00
Steve Strassmann
1f7bf1f00a use global LOG instead of local log 2013-05-12 21:52:07 -04:00
Steve Strassmann
1c5815a844 per-file log objects 2013-05-10 15:11:10 -04:00
Steve Strassmann
35d72f30b9 update .gitignore; fix logger import in execute.py 2013-05-10 14:40:30 -04:00
Steve Strassmann
beb4b39b73 fix logging 2013-05-08 14:25:31 -04:00
Steve Strassmann
d05ba84f13 /usr/bin/env in shebang line 2013-05-08 13:49:42 -04:00
Steve Strassmann
129c02f0b2 forgot to remove stale comment 2013-05-07 14:12:58 -04:00
Steve Strassmann
cf8d6b8965 factor logging out of library calls 2013-05-07 14:10:59 -04:00
Steve Strassmann
4620f50fb1 addressed Cale's comments; switched to path.py paths 2013-05-07 13:24:38 -04:00
Steve Strassmann
bec2ca4086 cleanup headers of files pulled from transifex. 2013-05-06 14:05:05 -04:00
Steve Strassmann
c0278d0ff1 refactor config file; fix duplicate merge 2013-05-06 11:29:27 -04:00
Steve Strassmann
55dd0fc8bc workaround for gettext parser bug 2013-05-03 12:45:55 -04:00
Steve Strassmann
8358e866cf more robust cleanup of default po files 2013-04-29 12:45:07 -04:00
Steve Strassmann
e287244151 rm test dir (replaced by tests dir) 2013-04-29 11:49:51 -04:00
Steve Strassmann
d63a37c252 rename test dir to tests; add SkipTest for test_extract.py 2013-04-29 11:47:56 -04:00
Steve Strassmann
393e6ffc23 added test cases for converter and dummy 2013-04-29 11:35:01 -04:00
Steve Strassmann
c00d71d422 integrate dummy string tools; added rake tasks and unit tests 2013-04-29 11:32:22 -04:00
Steve Strassmann
d55d5c9351 addressed Don\'s comments on pull request 2013-04-29 09:54:32 -04:00