Commit 63370a87 authored by Mathijs den Burger's avatar Mathijs den Burger Committed by Bert Leunis

CMS-11604 Use frontend-maven-plugin to build with NodeJs and NPM

(cherry picked from commit 98a25b0d)
parent c710a53f
......@@ -6,15 +6,20 @@
.project
.settings
.DS_Store
node_modules/
target/
/api/node/
/api/node_modules/
/api/repository/
/api/version/
/api/workspaces/
/automatic-export/repository/repository/
/automatic-export/repository/version/
/automatic-export/repository/workspaces/
/console/frontend/node/
/console/frontend/node_modules/
/editor/repository/workspaces/
/engine/node/
/engine/node_modules/
/richtext/frontend/repository/
/richtext/frontend/version/
/richtext/frontend/workspaces/
......
......@@ -297,26 +297,35 @@
<!-- Use NPM to install/build Hippo theme -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${maven.plugin.exec.version}</version>
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<executions>
<execution>
<id>npm-install</id>
<phase>generate-sources</phase>
<goals><goal>exec</goal></goals>
<id>install node and npm</id>
<goals>
<goal>install-node-and-npm</goal>
</goals>
<configuration>
<executable>npm</executable>
<commandlineArgs>ci</commandlineArgs>
<nodeVersion>${nodejs.version}</nodeVersion>
<npmVersion>${npm.version}</npmVersion>
</configuration>
</execution>
<execution>
<id>npm-build</id>
<phase>process-resources</phase>
<goals><goal>exec</goal></goals>
<id>npm ci</id>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<executable>npm</executable>
<commandlineArgs>run build</commandlineArgs>
<arguments>ci</arguments>
</configuration>
</execution>
<execution>
<id>npm run build</id>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<arguments>run build</arguments>
</configuration>
</execution>
</executions>
......@@ -338,9 +347,11 @@
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>node</directory>
</fileset>
<fileset>
<directory>node_modules</directory>
<followSymlinks>false</followSymlinks>
</fileset>
</filesets>
</configuration>
......
......@@ -213,26 +213,35 @@
<!-- Use NPM to install/build Hippo Console theme -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${maven.plugin.exec.version}</version>
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<executions>
<execution>
<id>npm-install</id>
<phase>generate-sources</phase>
<goals><goal>exec</goal></goals>
<id>install node and npm</id>
<goals>
<goal>install-node-and-npm</goal>
</goals>
<configuration>
<executable>npm</executable>
<commandlineArgs>ci</commandlineArgs>
<nodeVersion>${nodejs.version}</nodeVersion>
<npmVersion>${npm.version}</npmVersion>
</configuration>
</execution>
<execution>
<id>npm-build</id>
<phase>process-resources</phase>
<goals><goal>exec</goal></goals>
<id>npm ci</id>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<executable>npm</executable>
<commandlineArgs>run build</commandlineArgs>
<arguments>ci</arguments>
</configuration>
</execution>
<execution>
<id>npm run build</id>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<arguments>run build</arguments>
</configuration>
</execution>
</executions>
......@@ -241,9 +250,11 @@
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>node</directory>
</fileset>
<fileset>
<directory>node_modules</directory>
<followSymlinks>false</followSymlinks>
</fileset>
</filesets>
</configuration>
......
......@@ -172,17 +172,26 @@
<plugins>
<!-- Use NPM to fetch external JavaScript dependencies -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${maven.plugin.exec.version}</version>
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<executions>
<execution>
<id>npm-install</id>
<phase>generate-sources</phase>
<goals><goal>exec</goal></goals>
<id>install node and npm</id>
<goals>
<goal>install-node-and-npm</goal>
</goals>
<configuration>
<executable>npm</executable>
<commandlineArgs>ci</commandlineArgs>
<nodeVersion>${nodejs.version}</nodeVersion>
<npmVersion>${npm.version}</npmVersion>
</configuration>
</execution>
<execution>
<id>npm ci</id>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<arguments>ci</arguments>
</configuration>
</execution>
</executions>
......@@ -191,9 +200,11 @@
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>node</directory>
</fileset>
<fileset>
<directory>node_modules</directory>
<followSymlinks>false</followSymlinks>
</fileset>
</filesets>
</configuration>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment