lesscss-maven-plugin
lesscss-maven-plugin copied to clipboard
import-once doesn't work
I keep getting the following error when I use @import-once in place of @import:
[INFO] --- lesscss-maven-plugin:1.3.3:compile (default-cli) @ test-project --- [INFO] Compiling LESS source: base.less... [ERROR] /Users/virmani/workspace/server/src/main/resources/less/base.less [0:0]: Error compiling LESS source org.lesscss.LessException: Couldn't load undefineddev.less (0) at org.lesscss.LessCompiler.compile(LessCompiler.java:283) at org.lesscss.LessCompiler.compile(LessCompiler.java:335) at org.lesscss.LessCompiler.compile(LessCompiler.java:359) at org.lesscss.mojo.CompileMojo.execute(CompileMojo.java:131) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59) at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352) Caused by: org.mozilla.javascript.JavaScriptException: object Object at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:1018) at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:815) at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:109) at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:394) at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3091) at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:107) at org.lesscss.LessCompiler.compile(LessCompiler.java:270) ... 24 more
Same issue, did you find a workaround?
Nope. I had to change the import-once to import.
This is a show stopper for me. Can't use this compiler without import-once. Any alternatives to this plugin?
@import (once) http://lesscss.org/features/#import-options-once But it seems like only import options that I can get to work are (less) and (css)
The problem with imports is caused by "incorrect manual processing". I noticed that the plugin is not developed for a long time, so I wrote my own (https://github.com/gabrysbiz/lesscss-maven-plugin). I currently work only on documentation (I will release it in 2-3 weeks). I'll be grateful for any comments.
Ps. Marcel sorry for advertising my plugin on your site.