Tag: maven source plugin

maven-source-plugin不适用于kotlin

我正在尝试使用maven-source-plugin来为我的kotlin项目创建一个source.jar,但是似乎maven-source-plugin不适用于kotlin项目。 当我运行“mvn源:瓶”,输出消息总是说: [INFO] No sources in project. Archive not created. 这里是项目的pom文件中的maven-source-plugin配置: <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-source-plugin</artifactId> <version>2.2.1</version> <executions> <execution> <id>attach-sources</id> <phase>package</phase> <goals> <goal>jar</goal> </goals> <configuration> <attach>true</attach> <includes> <!– i am trying to specify the include dir manually, but not work –> <include>${project.basedir}/src/main/kotlin/*</include> </includes> <forceCreation>true</forceCreation> </configuration> </execution> </executions> </plugin> </plugins> </build> 我的问题是:如何使用maven-source-plugin附上kotlin源文件? 谢谢~~