blob: 14dbcf0fce0a36e61c587443c6d9b69b8de3c8f5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
function debug(str) {
//dump(' -*- l10n-clean.js: ' + str + '\n');
}
debug('Begin');
Gaia.webapps.forEach(function(webapp) {
// if BUILD_APP_NAME isn't `*`, we only accept one webapp
if (BUILD_APP_NAME != '*' && webapp.sourceDirectoryName != BUILD_APP_NAME)
return;
debug(webapp.sourceDirectoryName);
let re = new RegExp('\\.html\\.' + GAIA_DEFAULT_LOCALE + '$');
let files = ls(webapp.sourceDirectoryFile, true);
files.forEach(function(file) {
if (
re.test(file.leafName) ||
file.leafName.indexOf(Gaia.aggregatePrefix) === 0
) {
file.remove(false);
}
});
});
debug('End');
|