yui-compressor

Yui-compressor compiling error: variable oldCss is already defined in method compress(Writer,int)


I have downloaded yuicompressor and I am trying to compile it using "ant", but it gives me this error:

yuicompressor/build/build_tmp/com/yahoo/platform/yui/compressor/CssCompressor.java:341: error: variable oldCss is already defined in method compress(Writer,int) [javac] String oldCss;

Has anyone else ran into this problem? How do I solve it?


Solution

  • This guy has a fix and a pull request that is 29 days old as of now now: https://github.com/seyfahni/yuicompressor

    I did a 'git clone https://github.com/seyfahni/yuicompressor' and 'yum install ant'. Then 'ant' on the cli, it compiled yuicompressor-2.4.9.jar without issue. I hope this gets pulled into the master branch soon. The changes to source were minimal.