Repository navigation
API pom file
#43
|
The code snippet below 👇 is the best and min mall needs ㊙️ for the Pom file to copy the static asset into: src/main/resources/public 🙃 |
Answered by
ahmed82
Apr 21, 2022
Replies: 1 comment
|
The plugin and another needed 💯 JEE 🧾 required <build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<executable>true</executable>
</configuration>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>copy Vue.js frontend content</id>
<phase>generate-resources</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>src/main/resources/public</outputDirectory>
<overwrite>true</overwrite>
<resources>
<resource>
<directory>${project.parent.basedir}/license-management-vuejs/dist
</directory>
<includes>
<include>js/</include>
<include>css/</include>
<include>fonts/</include>
<include>img/</include>
<include>index.html</include>
<include>favicon.ico</include>
</includes>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<version>3.1.0</version>
<configuration>
<filesets>
<fileset>
<directory>src/main/resources/public</directory>
<includes>
<include>**/*</include>
</includes>
<excludes>
<exclude>**/important.log</exclude>
<exclude>**/another-important.log</exclude>
</excludes>
<followSymlinks>false</followSymlinks>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<failOnMissingWebXml>false</failOnMissingWebXml>
<archive>
<manifest>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
</manifest>
<manifestEntries>
<license-management-build-time>${maven.build.timestamp}</license-management-build-time>
<license-management-version>${project.version}</license-management-version>
</manifestEntries>
</archive>
<executable>true</executable>
</configuration>
</plugin>
</plugins>
<finalName>${parent.artifactId}</finalName>
</build> |
0 replies
Answer selected by
ahmed82
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The plugin and another needed 💯 JEE 🧾 required
pluginsadded within the -build- block