You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

寻求兼容新版Maven的活跃维护Less转CSS Maven插件

关于活跃维护的Less转CSS Maven插件的推荐请求

背景与问题

我有一个使用Less定义样式的Maven项目,许久未更新工具链。在新笔记本搭建环境时,发现此前用于编译Less的Gabrysbiz插件已与新版Maven不兼容,旧插件配置如下:

<plugin>
    <!-- http://www.gabrys.biz/projects/lesscss-maven-plugin/1.1/index.html -->
    <groupId>biz.gabrys.maven.plugins</groupId>
    <artifactId>lesscss-maven-plugin</artifactId>
    <version>1.2.1</version>
     .
     .
     .
</plugin>

执行Maven构建时出现类缺失错误:

[ERROR] Failed to execute goal biz.gabrys.maven.plugins:lesscss-maven-plugin:1.2.1:compile (default) on project services: Execution default of goal biz.gabrys.maven.plugins:lesscss-maven-plugin:1.2.1:compile failed: A required class was missing while executing biz.gabrys.maven.plugins:lesscss-maven-plugin:1.2.1:compile: org/codehaus/plexus/util/DirectoryScanner
[ERROR] -----------------------------------------------------
[ERROR] realm = plugin>biz.gabrys.maven.plugins:lesscss-maven-plugin:1.2.1
[ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[ERROR] urls[0] = file:/Users/sstanley/.m2/repository/biz/gabrys/maven/plugins/lesscss-maven-plugin/1.2.1/lesscss-maven-plugin-1.2.1.jar
[ERROR] urls[1] = file:/Users/sstanley/.m2/repository/biz/gabrys/lesscss/compiler/1.2.2/compiler-1.2.2.jar
[ERROR] urls[2] = file:/Users/sstanley/.m2/repository/org/mozilla/rhino/1.7R5/rhino-1.7R5.jar
[ERROR] urls[3] = file:/Users/sstanley/.m2/repository/biz/gabrys/lesscss/extended-compiler/2.1.0/extended-compiler-2.1.0.jar
[ERROR] urls[4] = file:/Users/sstanley/.m2/repository/commons-io/commons-io/2.2/commons-io-2.2.jar
[ERROR] urls[5] = file:/Users/sstanley/.m2/repository/org/apache/commons/commons-lang3/3.1/commons-lang3-3.1.jar
[ERROR] urls[6] = file:/Users/sstanley/.m2/repository/commons-net/commons-net/3.4/commons-net-3.4.jar
[ERROR] urls[7] = file:/Users/sstanley/.m2/repository/biz/gabrys/maven/plugin-utils/1.4.0/plugin-utils-1.4.0.jar
[ERROR] Number of foreign imports: 1
[ERROR] import: Entry[import from realm ClassRealm[maven.api, parent: null]]

经调试发现,该插件依赖Maven提供的plexus-utils,但新版Maven已不再包含该依赖,且该插件的GitHub仓库已归档3年。

已排查的候选插件

  • marceloverdijk/lesscss-maven-plugin:GitHub仓库已归档5年
  • Atlassian lesscss-maven-plugin:去年发布了新版本,但未找到相关文档
  • Javalite activeweb-lessc-maven-plugin:去年发布了新版本,有配套文档

求助

在深入研究这些插件之前,我想确认是否有遗漏的选项,LessCSS官网也未找到相关推荐。请问是否有推荐的、活跃维护的Less转CSS Maven插件?希望在投入时间迁移前获取相关建议。

内容的提问来源于stack exchange,提问作者Scott Stanley

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.28 14:24:54