Maven Mono 模块配置

这种易于使用和优化(无暂存)的配置仅适用于单模块 Maven 构建

使用以下配置,您可以简单地运行:mvn site-deploy

    <plugin>
      <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-site-plugin</artifactId>
      <configuration>
        <skipDeploy>true</skipDeploy><!-- don't deploy site with maven-site-plugin -->
      </configuration>
    </plugin>
    <plugin>
      <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-scm-publish-plugin</artifactId>
      <version>3.1.0</version>
      <configuration>
        <content>${project.reporting.outputDirectory}</content><!-- mono-module doesn't require site:stage -->
      </configuration>
      <executions>
        <execution>
          <id>scm-publish</id>
          <phase>site-deploy</phase><!-- deploy site with maven-scm-publish-plugin -->
          <goals>
            <goal>publish-scm</goal>
          </goals>
        </execution>
      </executions>
    </plugin>