maven 发布:执行失败甚至尝试生成 javadoc 或源

问题描述

自从不久前迁移到 Java 11 以来,maven 发布插件无法在生成的工件旁边生成 javadoc。我在父 pom(和编译器插件,如果相关)中的配置:

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.1</version>
                <configuration>
                    <release>11</release>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.2.0</version>
                <configuration>
                    <doclint>none</doclint>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>3.0.0-M4</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.2.1</version>
            </plugin>

如果我执行 mvn javadoc:javadoc,它工作正常。 如果我执行 mvn clean install -DperformRelease=true,它工作正常(javadoc 与主工件一起生成)。

但是如果我尝试进行真正的构建,使用 mvn release:prepare 后跟 mvn release:perform,我根本没有得到任何错误,事实上我没有任何迹象表明它甚至试图调用 javadoc 插件。我得到的唯一工件是主 JAR。

这是 mvn release:perform 输出的结尾,在测试全部通过后,它通常会生成 javadoc 和源代码,然后 maven-install-plugin 也会安装它们:

W:\test\momime-gitutilstest>mvn release:prepare
[INFO] Scanning for projects...
[INFO]
[INFO] ----------------------< com.ndg.common:git-utils >----------------------
[INFO] Building ndgUtils 0.4.5-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-release-plugin:3.0.0-M4:prepare (default-cli) @ git-utils ---
[INFO] phase verify-release-configuration
[INFO] starting prepare goal,composed of 17 phases: check-poms,scm-check-modifications,check-dependency-snapshots,create-backup-poms,map-release-versions,input-variables,map-development-versions,rewrite-poms-for-release,generate-release-poms,run-preparation-goals,scm-commit-release,scm-tag,rewrite-poms-for-development,remove-release-poms,run-completion-goals,scm-commit-development,end-release
[INFO] [prepare] 1/17 check-poms
[INFO] [prepare] 2/17 scm-check-modifications
[INFO] Verifying that there are no local modifications...
[INFO]   ignoring changes on: **\pom.xml.next,**\release.properties,**\pom.xml.branch,**\pom.xml.tag,**\pom.xml.backup,**\pom.xml.releaseBackup
[INFO] Executing: cmd.exe /X /C "git rev-parse --show-prefix"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git status --porcelain ."
[INFO] Working directory: W:\test\momime-gitutilstest
[WARNING] Ignoring unrecognized line: ?? release.properties
[INFO] [prepare] 3/17 check-dependency-snapshots
[INFO] Checking dependencies and plugins for snapshots ...
[INFO] [prepare] 4/17 create-backup-poms
[INFO] [prepare] 5/17 map-release-versions
What is the release version for "ndgUtils"? (com.ndg.common:git-utils) 0.4.5: :
[INFO] [prepare] 6/17 input-variables
What is the SCM release tag or label for "ndgUtils"? (com.ndg.common:git-utils) git-utils-0.4.5: :
[INFO] [prepare] 7/17 map-development-versions
What is the new development version for "ndgUtils"? (com.ndg.common:git-utils) 0.4.6-SNAPSHOT: :
[INFO] [prepare] 8/17 rewrite-poms-for-release
[INFO] Transforming 'ndgUtils'...
[INFO] [prepare] 9/17 generate-release-poms
[INFO] Not generating release POMs
[INFO] [prepare] 10/17 run-preparation-goals
[INFO] Executing goals 'clean verify'...
[WARNING] Maven will be executed in interactive mode,but no input stream has been configured for this MavenInvoker instance.
[INFO] [INFO] Scanning for projects...
[INFO] [INFO]
[INFO] [INFO] ----------------------< com.ndg.common:git-utils >----------------------
[INFO] [INFO] Building ndgUtils 0.4.5
[INFO] [INFO] --------------------------------[ jar ]---------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-clean-plugin:3.1.0:clean (default-clean) @ git-utils ---
[INFO] [INFO]
[INFO] [INFO] --- maven-jaxb2-plugin:0.14.0:generate (main-xjc-generate) @ git-utils ---
[INFO] [INFO] Sources are not up-to-date,XJC will be executed.
[INFO] WARNING: An illegal reflective access operation has occurred
[INFO] WARNING: Illegal reflective access by com.sun.xml.bind.v2.runtime.reflect.opt.Injector (file:/W:/maven/repository/org/glassfish/jaxb/jaxb-runtime/2.3.0/jaxb-runtime-2.3.0.jar) to method java.lang.classLoader.defineClass(java.lang.String,byte[],int,int)
[INFO] WARNING: Please consider reporting this to the maintainers of com.sun.xml.bind.v2.runtime.reflect.opt.Injector
[INFO] WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
[INFO] WARNING: All illegal access operations will be denied in a future release
[INFO] [INFO] Episode file [W:\test\momime-gitutilstest\target\generated-sources\xjc-layoutmanagers\meta-inf\layoutmanagers.episode] was augmented with if-exists="true" attributes.
[INFO] [INFO]
[INFO] [INFO] --- maven-resources-plugin:3.2.0:resources (default-resources) @ git-utils ---
[INFO] [INFO] Using 'cp1252' encoding to copy filtered resources.
[INFO] [INFO] Using 'cp1252' encoding to copy filtered properties files.
[INFO] [INFO] copying 1 resource
[INFO] [INFO] copying 1 resource
[INFO] [INFO]
[INFO] [INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ git-utils ---
[INFO] [INFO] Changes detected - recompiling the module!
[INFO] [INFO] Compiling 52 source files to W:\test\momime-gitutilstest\target\classes
[INFO] [INFO]
[INFO] [INFO] --- maven-resources-plugin:3.2.0:testResources (default-testResources) @ git-utils ---
[INFO] [INFO] Using 'cp1252' encoding to copy filtered resources.
[INFO] [INFO] Using 'cp1252' encoding to copy filtered properties files.
[INFO] [INFO] copying 2 resources
[INFO] [INFO]
[INFO] [INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @ git-utils ---
[INFO] [INFO] Changes detected - recompiling the module!
[INFO] [INFO] Compiling 20 source files to W:\test\momime-gitutilstest\target\test-classes
[INFO] [INFO]
[INFO] [INFO] --- maven-surefire-plugin:3.0.0-M5:test (default-test) @ git-utils ---
[INFO] [INFO]
[INFO] [INFO] -------------------------------------------------------
[INFO] [INFO]  T E S T S
[INFO] [INFO] -------------------------------------------------------
[INFO] [INFO] Running com.ndg.math.TestRomanNumerals
[INFO] [INFO] Tests run: 2,Failures: 0,Errors: 0,Skipped: 0,Time elapsed: 0.144 s - in com.ndg.math.TestRomanNumerals
[INFO] [INFO] Running com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutContainerExImpl
[INFO] [INFO] Tests run: 2,Time elapsed: 0 s - in com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutContainerExImpl
[INFO] [INFO] Running com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutManager
[INFO] Jul. 11,2021 11:27:48 A.M. com.ndg.swing.layoutmanagers.xmllayout.XmlLayoutManager layoutContainer
[INFO] WARNING: No entry in XML layout was found for component with name "ButtonFour"
[INFO] [INFO] Tests run: 1,Time elapsed: 5.894 s - in com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutManager
[INFO] [INFO] Running com.ndg.swing.TestJPanelWithConstantRepaints
[INFO] [INFO] Tests run: 1,Time elapsed: 5.07 s - in com.ndg.swing.TestJPanelWithConstantRepaints
[INFO] [INFO] Running com.ndg.swing.TestMouseClickListener
[INFO] [INFO] Tests run: 1,Time elapsed: 5.067 s - in com.ndg.swing.TestMouseClickListener
[INFO] [INFO] Running com.ndg.utils.FileNameUtilsTest
[INFO] [INFO] Tests run: 3,Time elapsed: 0.044 s - in com.ndg.utils.FileNameUtilsTest
[INFO] [INFO] Running com.ndg.utils.NumberUtilsTest
[INFO] [INFO] Tests run: 1,Time elapsed: 0.001 s - in com.ndg.utils.NumberUtilsTest
[INFO] [INFO] Running com.ndg.utils.ProcessUtilsImpltest
[INFO] [INFO] Tests run: 3,Time elapsed: 0 s - in com.ndg.utils.ProcessUtilsImpltest
[INFO] [INFO] Running com.ndg.utils.stream.BooleanTest
[INFO] [INFO] Tests run: 2,Time elapsed: 0.017 s - in com.ndg.utils.stream.BooleanTest
[INFO] [INFO] Running com.ndg.utils.stream.DelphiDateTest
[INFO] [INFO] Tests run: 2,Time elapsed: 0.001 s - in com.ndg.utils.stream.DelphiDateTest
[INFO] [INFO] Running com.ndg.utils.stream.DoubleTest
[INFO] [INFO] Tests run: 3,Time elapsed: 0.001 s - in com.ndg.utils.stream.DoubleTest
[INFO] [INFO] Running com.ndg.utils.stream.LengthAndStringTest
[INFO] [INFO] Tests run: 5,Time elapsed: 0 s - in com.ndg.utils.stream.LengthAndStringTest
[INFO] [INFO] Running com.ndg.utils.stream.Signed2ByteShortTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0.003 s - in com.ndg.utils.stream.Signed2ByteShortTest
[INFO] [INFO] Running com.ndg.utils.stream.Signed4ByteIntTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0 s - in com.ndg.utils.stream.Signed4ByteIntTest
[INFO] [INFO] Running com.ndg.utils.stream.Signed8ByteLongTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0.001 s - in com.ndg.utils.stream.Signed8ByteLongTest
[INFO] [INFO] Running com.ndg.utils.stream.Unsigned2ByteIntTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0 s - in com.ndg.utils.stream.Unsigned2ByteIntTest
[INFO] [INFO] Running com.ndg.utils.stream.Unsigned4ByteLongTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0.001 s - in com.ndg.utils.stream.Unsigned4ByteLongTest
[INFO] [INFO] Running com.ndg.utils.StringUtilsTest
[INFO] [INFO] Tests run: 3,Time elapsed: 0.002 s - in com.ndg.utils.StringUtilsTest
[INFO] [INFO]
[INFO] [INFO] Results:
[INFO] [INFO]
[INFO] [INFO] Tests run: 49,Skipped: 0
[INFO] [INFO]
[INFO] [INFO]
[INFO] [INFO] --- maven-jar-plugin:3.2.0:jar (default-jar) @ git-utils ---
[INFO] [INFO] Building jar: W:\test\momime-gitutilstest\target\git-utils-0.4.5.jar
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] BUILD SUCCESS
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] Total time:  22.750 s
[INFO] [INFO] Finished at: 2021-07-11T11:28:04-02:30
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [prepare] 11/17 scm-commit-release
[INFO] Checking in modified POMs...
[INFO] Executing: cmd.exe /X /C "git add -- pom.xml"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git rev-parse --show-prefix"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git status --porcelain ."
[INFO] Working directory: W:\test\momime-gitutilstest
[WARNING] Ignoring unrecognized line: ?? pom.xml.releaseBackup
[WARNING] Ignoring unrecognized line: ?? release.properties
[WARNING] Ignoring unrecognized line: ?? target/
[INFO] Executing: cmd.exe /X /C "git commit --verbose -F C:\Users\NIGELG~1\AppData\Local\Temp\maven-scm-1323264089.commit"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git symbolic-ref HEAD"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git push ssh:********@git.code.sf.net/p/momime/gitutilstest refs/heads/develop:refs/heads/develop"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] [prepare] 12/17 scm-tag
[INFO] Tagging release with the label git-utils-0.4.5...
[INFO] Executing: cmd.exe /X /C "git tag -F C:\Users\NIGELG~1\AppData\Local\Temp\maven-scm-79680122.commit git-utils-0.4.5"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git push ssh:********@git.code.sf.net/p/momime/gitutilstest refs/tags/git-utils-0.4.5"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git ls-files"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] [prepare] 13/17 rewrite-poms-for-development
[INFO] Transforming 'ndgUtils'...
[INFO] [prepare] 14/17 remove-release-poms
[INFO] Not removing release POMs
[INFO] [prepare] 15/17 run-completion-goals
[INFO] [prepare] 16/17 scm-commit-development
[INFO] Checking in modified POMs...
[INFO] Executing: cmd.exe /X /C "git add -- pom.xml"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git rev-parse --show-prefix"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git status --porcelain ."
[INFO] Working directory: W:\test\momime-gitutilstest
[WARNING] Ignoring unrecognized line: ?? pom.xml.releaseBackup
[WARNING] Ignoring unrecognized line: ?? release.properties
[WARNING] Ignoring unrecognized line: ?? target/
[INFO] Executing: cmd.exe /X /C "git commit --verbose -F C:\Users\NIGELG~1\AppData\Local\Temp\maven-scm-2027775157.commit"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git symbolic-ref HEAD"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] Executing: cmd.exe /X /C "git push ssh:********@git.code.sf.net/p/momime/gitutilstest refs/heads/develop:refs/heads/develop"
[INFO] Working directory: W:\test\momime-gitutilstest
[INFO] [prepare] 17/17 end-release
[INFO] Release preparation complete.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  49.197 s
[INFO] Finished at: 2021-07-11T11:28:14-02:30
[INFO] ------------------------------------------------------------------------

















W:\test\momime-gitutilstest>mvn release:perform
[INFO] Scanning for projects...
[INFO]
[INFO] ----------------------< com.ndg.common:git-utils >----------------------
[INFO] Building ndgUtils 0.4.6-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-release-plugin:3.0.0-M4:perform (default-cli) @ git-utils ---
[INFO] phase verify-release-configuration
[INFO] starting perform goal,composed of 3 phases: verify-completed-prepare-phases,checkout-project-from-scm,run-perform-goals
[INFO] [perform] 1/3 verify-completed-prepare-phases
[INFO] [perform] 2/3 checkout-project-from-scm
[INFO] Checking out the project to perform the release ...
[INFO] Executing: cmd.exe /X /C "git clone --depth 1 --branch git-utils-0.4.5 ssh:********@git.code.sf.net/p/momime/gitutilstest checkout"
[INFO] Working directory: W:\test\momime-gitutilstest\target
[INFO] Executing: cmd.exe /X /C "git ls-remote ssh:********@git.code.sf.net/p/momime/gitutilstest"
[INFO] Working directory: C:\Users\NIGELG~1\AppData\Local\Temp
[INFO] Executing: cmd.exe /X /C "git fetch ssh:********@git.code.sf.net/p/momime/gitutilstest"
[INFO] Working directory: W:\test\momime-gitutilstest\target\checkout
[INFO] Executing: cmd.exe /X /C "git checkout git-utils-0.4.5"
[INFO] Working directory: W:\test\momime-gitutilstest\target\checkout
[INFO] Executing: cmd.exe /X /C "git ls-files"
[INFO] Working directory: W:\test\momime-gitutilstest\target\checkout
[INFO] [perform] 3/3 run-perform-goals
[INFO] Invoking perform goals in directory W:\test\momime-gitutilstest\target\checkout
[INFO] Executing goals 'deploy'...
[INFO] pomFileName is already set,ignoring the -f argument
[WARNING] Maven will be executed in interactive mode,but no input stream has been configured for this MavenInvoker instance.
[INFO] [INFO] Scanning for projects...
[INFO] [INFO]
[INFO] [INFO] ----------------------< com.ndg.common:git-utils >----------------------
[INFO] [INFO] Building ndgUtils 0.4.5
[INFO] [INFO] --------------------------------[ jar ]---------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-jaxb2-plugin:0.14.0:generate (main-xjc-generate) @ git-utils ---
[INFO] [INFO] Sources are not up-to-date,int)
[INFO] WARNING: Please consider reporting this to the maintainers of com.sun.xml.bind.v2.runtime.reflect.opt.Injector
[INFO] WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
[INFO] WARNING: All illegal access operations will be denied in a future release
[INFO] [INFO] Episode file [W:\test\momime-gitutilstest\target\checkout\target\generated-sources\xjc-layoutmanagers\meta-inf\layoutmanagers.episode] was augmented with if-exists="true" attributes.
[INFO] [INFO]
[INFO] [INFO] --- maven-resources-plugin:3.2.0:resources (default-resources) @ git-utils ---
[INFO] [INFO] Using 'cp1252' encoding to copy filtered resources.
[INFO] [INFO] Using 'cp1252' encoding to copy filtered properties files.
[INFO] [INFO] copying 1 resource
[INFO] [INFO] copying 1 resource
[INFO] [INFO]
[INFO] [INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ git-utils ---
[INFO] [INFO] Changes detected - recompiling the module!
[INFO] [INFO] Compiling 52 source files to W:\test\momime-gitutilstest\target\checkout\target\classes
[INFO] [INFO]
[INFO] [INFO] --- maven-resources-plugin:3.2.0:testResources (default-testResources) @ git-utils ---
[INFO] [INFO] Using 'cp1252' encoding to copy filtered resources.
[INFO] [INFO] Using 'cp1252' encoding to copy filtered properties files.
[INFO] [INFO] copying 2 resources
[INFO] [INFO]
[INFO] [INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @ git-utils ---
[INFO] [INFO] Changes detected - recompiling the module!
[INFO] [INFO] Compiling 20 source files to W:\test\momime-gitutilstest\target\checkout\target\test-classes
[INFO] [INFO]
[INFO] [INFO] --- maven-surefire-plugin:3.0.0-M5:test (default-test) @ git-utils ---
[INFO] [INFO]
[INFO] [INFO] -------------------------------------------------------
[INFO] [INFO]  T E S T S
[INFO] [INFO] -------------------------------------------------------
[INFO] [INFO] Running com.ndg.math.TestRomanNumerals
[INFO] [INFO] Tests run: 2,Time elapsed: 0.17 s - in com.ndg.math.TestRomanNumerals
[INFO] [INFO] Running com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutContainerExImpl
[INFO] [INFO] Tests run: 2,Time elapsed: 0.001 s - in com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutContainerExImpl
[INFO] [INFO] Running com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutManager
[INFO] Jul. 11,2021 11:28:39 A.M. com.ndg.swing.layoutmanagers.xmllayout.XmlLayoutManager layoutContainer
[INFO] WARNING: No entry in XML layout was found for component with name "ButtonFour"
[INFO] [INFO] Tests run: 1,Time elapsed: 5.954 s - in com.ndg.swing.layoutmanagers.xmllayout.TestXmlLayoutManager
[INFO] [INFO] Running com.ndg.swing.TestJPanelWithConstantRepaints
[INFO] [INFO] Tests run: 1,Time elapsed: 5.054 s - in com.ndg.swing.TestJPanelWithConstantRepaints
[INFO] [INFO] Running com.ndg.swing.TestMouseClickListener
[INFO] [INFO] Tests run: 1,Time elapsed: 5.043 s - in com.ndg.swing.TestMouseClickListener
[INFO] [INFO] Running com.ndg.utils.FileNameUtilsTest
[INFO] [INFO] Tests run: 3,Time elapsed: 0.049 s - in com.ndg.utils.FileNameUtilsTest
[INFO] [INFO] Running com.ndg.utils.NumberUtilsTest
[INFO] [INFO] Tests run: 1,Time elapsed: 0.012 s - in com.ndg.utils.stream.BooleanTest
[INFO] [INFO] Running com.ndg.utils.stream.DelphiDateTest
[INFO] [INFO] Tests run: 2,Time elapsed: 0 s - in com.ndg.utils.stream.DelphiDateTest
[INFO] [INFO] Running com.ndg.utils.stream.DoubleTest
[INFO] [INFO] Tests run: 3,Time elapsed: 0 s - in com.ndg.utils.stream.DoubleTest
[INFO] [INFO] Running com.ndg.utils.stream.LengthAndStringTest
[INFO] [INFO] Tests run: 5,Time elapsed: 0.001 s - in com.ndg.utils.stream.LengthAndStringTest
[INFO] [INFO] Running com.ndg.utils.stream.Signed2ByteShortTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0.001 s - in com.ndg.utils.stream.Signed2ByteShortTest
[INFO] [INFO] Running com.ndg.utils.stream.Signed4ByteIntTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0.001 s - in com.ndg.utils.stream.Signed4ByteIntTest
[INFO] [INFO] Running com.ndg.utils.stream.Signed8ByteLongTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0 s - in com.ndg.utils.stream.Signed8ByteLongTest
[INFO] [INFO] Running com.ndg.utils.stream.Unsigned2ByteIntTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0.001 s - in com.ndg.utils.stream.Unsigned2ByteIntTest
[INFO] [INFO] Running com.ndg.utils.stream.Unsigned4ByteLongTest
[INFO] [INFO] Tests run: 4,Time elapsed: 0 s - in com.ndg.utils.stream.Unsigned4ByteLongTest
[INFO] [INFO] Running com.ndg.utils.StringUtilsTest
[INFO] [INFO] Tests run: 3,Time elapsed: 0.003 s - in com.ndg.utils.StringUtilsTest
[INFO] [INFO]
[INFO] [INFO] Results:
[INFO] [INFO]
[INFO] [INFO] Tests run: 49,Skipped: 0
[INFO] [INFO]
[INFO] [INFO]
[INFO] [INFO] --- maven-jar-plugin:3.2.0:jar (default-jar) @ git-utils ---
[INFO] [INFO] Building jar: W:\test\momime-gitutilstest\target\checkout\target\git-utils-0.4.5.jar
[INFO] [INFO]
[INFO] [INFO] --- maven-install-plugin:3.0.0-M1:install (default-install) @ git-utils ---
[INFO] [INFO] Installing W:\test\momime-gitutilstest\target\checkout\target\git-utils-0.4.5.jar to W:\maven\repository\com\ndg\common\git-utils\0.4.5\git-utils-0.4.5.jar
[INFO] [INFO] Installing W:\test\momime-gitutilstest\target\checkout\pom.xml to W:\maven\repository\com\ndg\common\git-utils\0.4.5\git-utils-0.4.5.pom
[INFO] [INFO]
[INFO] [INFO] --- maven-deploy-plugin:3.0.0-M1:deploy (default-deploy) @ git-utils ---

无休止地寻找解决方案,但大多数帖子要么是a)javadoc生成失败的人,因为他们没有doclint=none,要么b)人们想要完全改变javadoc生成。我找不到有关如何打开它的任何信息,因为认情况下它应该打开。任何建议将不胜感激,谢谢。

(编辑:也为 maven-source-plugin 添加了父 pom 配置和 SO 标记,因为它具有完全相同的问题,因为它只是无法运行)

解决方法

经过大量搜索和尝试不起作用的事情后,最终将其跟踪到必须添加的此设置。虽然我仍然感到困惑,在过去没有这个的情况下,这可以正常工作,所以他们一定是将默认值从 true 更改为 false。

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>3.0.0-M4</version>
                <configuration>
                    <useReleaseProfile>true</useReleaseProfile>
                </configuration>
            </plugin>

更新:是的,检查了发布插件的版本 - 在 3.0.0-M4 useReleaseProfile 默认为 true,在 2.5.3(最新的 2.x.x)中默认为 false。

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...