User tests: Successful: 0 Unsuccessful: 0
Pull Request for Issue #24144 .
Status | New | ⇒ | Pending |
Category | ⇒ | JavaScript Repository |
@bembelimen I think is better to continue with a then, like:
// Loop to get the files that should be compiled via parameter
folders.forEach((folder) => {
Recurs(folder, ['*.js', '*.map', '*.svg', '*.png', '*.gif', '*.swf', '*.html', '*.json']).then(
(filesRc) => {
filesRc.forEach(
(file) => {
// Don't take files with "_" but "file" has the full path, so check via match
if (file.match(/\.scss$/) && !file.match(/(\/|\\)_[^\/\\]+$/)) {
files.push(file);
}
if (file.match(/\.css/)) {
// CSS file, we will copy the file and then minify it in place
// Ensure that the directories exist or create them
MakeDir.run(Path.dirname(file).replace('/build/media_source/', '/media/').replace('\\build\\media_source\\', '\\media\\'));
Fs.copyFileSync(file, file.replace('/build/media_source/', '/media/').replace('\\build\\media_source\\', '\\media\\'));
Fs.writeFileSync(
file.replace('/build/media_source/', '/media/').replace('\\build\\media_source\\', '\\media\\').replace('.css', '.min.css'),
UglyCss.processFiles([file], { expandVars: false }),
{ encoding: 'utf8' },
);
// eslint-disable-next-line no-console
console.log(`CSS file copied/minified: ${file}`);
}
},
(error) => {
// eslint-disable-next-line no-console
console.error(`something exploded ${error}`);
},
);
return files;
},
).then(theFiles => {
theFiles.forEach((inputFile) => {
CompileScss.compile(inputFile, options);
});
});
});
Also why the heck are there still GIF files in the media folder? It's 2019...
@bembelimen I think is better to continue with a then, like:
Thanks, that's exactly the feedback I needed!
Also why the heck are there still GIF files in the media folder? It's 2019...
https://github.com/joomla/joomla-cms/tree/4.0-dev/build/media_source/mod_languages/images
Labels |
Added:
?
|
Title |
|
From my logs after running this
Transpiling ES6 file: C:\htdocs\joomla-cms\build\media_source\system\js\fields\passwordview.es6.js
Transpiling ES6 file: C:\htdocs\joomla-cms\build\media_source\system\js\fields\passwordview.es6.js
Transpiling ES6 file: C:\htdocs\joomla-cms\build\media_source\system\js\fields\passwordview.es6.js
Transpiling ES6 file: C:\htdocs\joomla-cms\build\media_source\system\js\fields\passwordview.es6.js
this was what happened for all es6
And on my windows system the paths were being written differently depending on the location
SCSS File compiled: C:\htdocs\joomla-cms\media\plg_installer_webinstaller\css\client.css
SCSS File compiled: C:\htdocs\joomla-cms/installation/template/css/template.css
@brianteeman it's fine
I have tested this item
Before patch the following files were compiled
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/templates/cassiopeia/css/offline.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/bootstrap.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/template.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/font-awesome.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/template-rtl.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/templates/cassiopeia/css/template-rtl.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/templates/cassiopeia/css/template.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/installation/template/css/template.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/installation/template/css/template-rtl.css
After patch:
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/templates/cassiopeia/css/offline.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/font-awesome.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/template.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/bootstrap.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/administrator/templates/atum/css/template-rtl.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/templates/cassiopeia/css/template.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/media/system/css/fields/joomla-field-simple-color.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/templates/cassiopeia/css/template-rtl.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/media/system/css/fields/joomla-field-switcher.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/media/system/css/fields/joomla-field-permissions.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/media/system/css/fields/joomla-field-media.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/media/plg_installer_webinstaller/css/client.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/installation/template/css/template.css
SCSS File compiled: /Users/georgewilson/workspace/opensource/joomla-cms/installation/template/css/template-rtl.css
So it seemed to find a bunch of extra files so I think this patch works on OSX
Status | Pending | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2019-03-14 16:24:44 |
Closed_By | ⇒ | wilsonge |
Thanks!
@dgrammatiko perhaps you have some seconds to look, if you agree with the changes? Thanks!