mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 17:30:09 +02:00
Merge pull request #4504 from timvandermeij/importl10n
Import l10n files from mozilla-aurora
This commit is contained in:
commit
5fc806823e
207 changed files with 13656 additions and 1641 deletions
21
make.js
21
make.js
|
@ -202,7 +202,7 @@ target.locale = function() {
|
|||
if (!test('-d', path)) {
|
||||
continue;
|
||||
}
|
||||
if (!/^[a-z][a-z](-[A-Z][A-Z])?$/.test(locale)) {
|
||||
if (!/^[a-z][a-z]([a-z])?(-[A-Z][A-Z])?$/.test(locale)) {
|
||||
echo('Skipping invalid locale: ' + locale);
|
||||
continue;
|
||||
}
|
||||
|
@ -1311,3 +1311,22 @@ target.makefile = function() {
|
|||
makefileContent += '.PHONY: ' + targetsNames.join(' ') + '\n';
|
||||
makefileContent.to('Makefile');
|
||||
};
|
||||
|
||||
//
|
||||
//make importl10n
|
||||
//
|
||||
target.importl10n = function() {
|
||||
var locales = require('./external/importL10n/locales.js');
|
||||
var LOCAL_L10N_DIR = 'l10n';
|
||||
|
||||
cd(ROOT_DIR);
|
||||
echo();
|
||||
echo('### Importing translations from mozilla-aurora');
|
||||
|
||||
if (!test('-d', LOCAL_L10N_DIR)) {
|
||||
mkdir(LOCAL_L10N_DIR);
|
||||
}
|
||||
cd(LOCAL_L10N_DIR);
|
||||
|
||||
locales.downloadL10n();
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue