Hi Frank,
thanks for your report. I can't replicate that on my Mac right now and I will be out of office for two weeks starting this evening. If you can provide me with more detailes errors (stacktraces), I'll promise to look into that issue once I'm back.
Cheers,
Carsten
----- Ursprüngliche Mail -----
Von: "Frank" <
[hidden email]>
An:
[hidden email]
Gesendet: Freitag, 11. November 2011 03:36:19
Betreff: Re: [grails-user] Resources Plugins (lesscss-resources + yui-minify-resources = JavaScript-Minify-Problems)
Hi Carsten
thanks a lot for having a look at this.
I just downloaded and tested your sample application, but for me, the yuiminifyresources.YuiJsMinifyResourceMapper throws some errors.
Here are some sample errors:
| Error 2011-11-11 02:27:10,274 [Thread-9] ERROR yuiminifyresources.YuiJsMinifyResourceMapper - Stopped minifying [/home/liefra/.grails/2.0.0.RC1/projects/yuiminify20/tomcat/work/Tomcat/localhost/yuiminify20/grails-resources/plugins/enhanced-scaffolding-1.0.RC2/js/grails.alerts.loader.js]: null Set log level to warn for more details.
| Error 2011-11-11 02:27:10,286 [Thread-9] ERROR yuiminifyresources.YuiJsMinifyResourceMapper - Stopped minifying [/home/liefra/.grails/2.0.0.RC1/projects/yuiminify20/tomcat/work/Tomcat/localhost/yuiminify20/grails-resources/plugins/enhanced-scaffolding-1.0.RC2/js/grails.forms.js]: null Set log level to warn for more details.
| Error 2011-11-11 02:27:10,291 [Thread-9] ERROR yuiminifyresources.YuiJsMinifyResourceMapper - Stopped minifying [/home/liefra/.grails/2.0.0.RC1/projects/yuiminify20/tomcat/work/Tomcat/localhost/yuiminify20/grails-resources/plugins/enhanced-scaffolding-1.0.RC2/js/grails.fouc.js]: null Set log level to warn for more details.
These errors are reported for all twitter-bootstrap and enhanced-scaffolding js files.
The included /yuiminify20/static/bundle-scaffolding_defer.js js file contains no minified js code
I'm running Fedora 16/64bit
Best, Frank
On 11/10/2011 07:19 PM, Carsten A. Block wrote:
Hi Kosta,
sorry for my late reply. Today I tried out combinging less-css resources and yui-minify-resources and it works fine for me. Please find my sample application at:
https://github.com/cblock/yui-minify-resources/downloads In that app I installed the following plugins:
* resources 1.1.1
* yui-minify-resources 0.1.4
* lesscss-resources 0.6.1
* twitter-bootstrap 1.4.0.12
* enhanced-scaffolding 1.0.RC2
Also, I added the following two lines to Config.groovy:
grails.resources.mappers.yuicssminify.includes = ['**/*.less','**/*.css']
grails.resources.mappers.lesscss.excludes = ['**/*.css','**/*.js','**/*.png','**/*.gif','**/*.jpg','**/*.jpeg','**/*.gz','**/*.zip']
Note: twitter-bootstrap uses the less version of the framework as soon as lesscss-resources is installed, and enhanced-scaffolding provides several uncompressed js files. When running the app, all files are correctly transformed / packaged / minified - at least on my computer.
So maybe your problem stems from your own javascript file? Try minifying the file manually using the yui-compressor lib or an online service such as
http://www.refresh-sf.com/yui/ . Also, you might want to set the log level for the resource mappers in your application to debug to better trace the mapping process:
Config.groovy:
debug 'org.grails.plugin.resource',
'org.grails.plugin.resource.yuijsminify',
'org.grails.plugin.resource.yuicssminify',
Best,
Carsten
----- Ursprüngliche Mail -----
Von: "Marc Palmer" <
[hidden email]> An:
[hidden email] Gesendet: Donnerstag, 27. Oktober 2011 13:51:59
Betreff: Re: [grails-user] Resources Plugins (lesscss-resources + yui-minify-resources = JavaScript-Minify-Problems)
On 27 Oct 2011, at 09:37, Konstantinos Kostarellis wrote:
<blockquote>
Is someone using resources like this ?
Is there somebody experiencing similar problems ?
2011/10/24 Konstantinos Kostarellis <
[hidden email]> When I add the 2 resources plugins:
compile ":lesscss-resources:0.6.1"
compile ":yui-minify-resources:0.1.2"
in the projects BuildConfig.groovy the minification of JavaScript-Files is broken.
I get the following error messages at startup-time (run-app).
| Error 2011-10-24 15:35:15,799 [Thread-9] ERROR yuiminifyresources.YuiJsMinifyResourceMapper - Stopped minifying [/home/kosta/.grails/2.0.0.RC1/projects/MProj/tomcat/work/Tomcat/localhost/MProj/grails-resources/js/application.js]: null Set log level to warn for more details.
The result is that the js - file is not minified. Thats odd cause less doesn't do anything with JavaScript files.
Besides I couln't get them working together even thou, they seem to be working in the right mapper phases.
Any experts on resources ? Marc ?
Hi Kosta,
I haven't tried those two plugins together yet I'm afraid.
Did you set log level to "warn" as instructed - what did it say? It looks like something from the YUI minifier. Perhaps it is processing before "less" and choking on the syntax of the files?
Marc
~ ~ ~
Marc Palmer
Freelancer (Grails/Groovy/Java)
Founder @
http://noticelocal.com | Developer @
http://weceem.org Member @
http://spottymushroom.com | Contributor @
http://grails.org Twitter:
http://twitter.com/wangjammer5 | Resumé:
http://www.anyware.co.uk/marc/ Blog:
http://www.anyware.co.uk | Grails Rocks:
http://www.grailsrocks.com ---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email ---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email</blockquote>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email