You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by al...@apache.org on 2015/04/02 06:05:34 UTC
ambari git commit: AMBARI-10303. Install node / brunch and other
build dependencies at build time. Additional patch(4). (alexantonenko)
Repository: ambari
Updated Branches:
refs/heads/trunk 3f452debd -> ce6255033
AMBARI-10303. Install node / brunch and other build dependencies at build time. Additional patch(4). (alexantonenko)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/ce625503
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/ce625503
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/ce625503
Branch: refs/heads/trunk
Commit: ce6255033dd0ee8a8c85d8d46f8d4c0d6bb8ff74
Parents: 3f452de
Author: Alex Antonenko <hi...@gmail.com>
Authored: Thu Apr 2 07:03:09 2015 +0300
Committer: Alex Antonenko <hi...@gmail.com>
Committed: Thu Apr 2 07:05:29 2015 +0300
----------------------------------------------------------------------
ambari-web/pom.xml | 74 +++++++++++++++++++++++++++++++++++++------------
pom.xml | 16 ++++++-----
2 files changed, 66 insertions(+), 24 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/ce625503/ambari-web/pom.xml
----------------------------------------------------------------------
diff --git a/ambari-web/pom.xml b/ambari-web/pom.xml
index 04f9b5d..3746454 100644
--- a/ambari-web/pom.xml
+++ b/ambari-web/pom.xml
@@ -87,6 +87,23 @@
</configuration>
</plugin>
<plugin>
+ <groupId>com.github.eirslett</groupId>
+ <artifactId>frontend-maven-plugin</artifactId>
+ <version>0.0.19</version>
+ <executions>
+ <execution>
+ <id>install node and npm</id>
+ <goals>
+ <goal>install-node-and-npm</goal>
+ </goals>
+ <configuration>
+ <nodeVersion>v0.10.31</nodeVersion>
+ <npmVersion>1.4.23</npmVersion>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.2.1</version>
@@ -100,7 +117,7 @@
<configuration>
<executable>${executable.rmdir}</executable>
<workingDirectory>${basedir}</workingDirectory>
- <commandlineArgs>${args.rm.clean} public node_modules</commandlineArgs>
+ <commandlineArgs>${args.rm.clean} public node_modules node</commandlineArgs>
<successCodes>
<successCode>0</successCode>
<successCode>1</successCode>
@@ -117,19 +134,43 @@
<configuration>
<executable>${executable.mkdir}</executable>
<workingDirectory>${basedir}</workingDirectory>
- <commandlineArgs>${args.mkdir} public</commandlineArgs>
+ <commandlineArgs>${args.mkdir} public node</commandlineArgs>
+ </configuration>
+ </execution>
+ <execution>
+ <id>npm-cache-clean</id>
+ <phase>compile</phase>
+ <goals>
+ <goal>exec</goal>
+ </goals>
+ <configuration>
+ <executable>${executable.node}</executable>
+ <workingDirectory>${basedir}</workingDirectory>
+ <commandlineArgs>${args.npm.full.path} cache clean</commandlineArgs>
+ </configuration>
+ </execution>
+ <execution>
+ <id>install-npm</id>
+ <phase>compile</phase>
+ <goals>
+ <goal>exec</goal>
+ </goals>
+ <configuration>
+ <executable>${executable.node}</executable>
+ <workingDirectory>${basedir}</workingDirectory>
+ <commandlineArgs>${args.npm.full.path} install</commandlineArgs>
</configuration>
</execution>
<execution>
- <id>compile-npm</id>
+ <id>install-brunch</id>
<phase>compile</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
- <executable>${executable.npm}</executable>
+ <executable>${executable.node}</executable>
<workingDirectory>${basedir}</workingDirectory>
- <commandlineArgs>${args.npm} install</commandlineArgs>
+ <commandlineArgs>${args.npm.full.path} install brunch@v1.7.20</commandlineArgs>
</configuration>
</execution>
<execution>
@@ -139,9 +180,9 @@
<goal>exec</goal>
</goals>
<configuration>
- <executable>${executable.brunch}</executable>
+ <executable>${executable.node}</executable>
<workingDirectory>${basedir}</workingDirectory>
- <commandlineArgs>${args.brunch} build</commandlineArgs>
+ <commandlineArgs>${args.brunch.full.path} build</commandlineArgs>
</configuration>
</execution>
<execution>
@@ -191,9 +232,9 @@
</goals>
<configuration>
<skip>${skipTests}</skip>
- <executable>${executable.npm}</executable>
+ <executable>${executable.node}</executable>
<workingDirectory>${basedir}</workingDirectory>
- <commandlineArgs>${args.npm} test</commandlineArgs>
+ <commandlineArgs>${args.npm.full.path} test</commandlineArgs>
</configuration>
</execution>
<execution>
@@ -227,6 +268,7 @@
<exclude>app/assets/**</exclude>
<exclude>vendor/**</exclude>
<exclude>node_modules/**</exclude>
+ <exclude>node/**</exclude>
<exclude>npm-debug.log</exclude>
</excludes>
</configuration>
@@ -269,18 +311,17 @@
<properties>
<envClassifier>win</envClassifier>
<dirsep>\</dirsep>
- <executable.brunch>cmd</executable.brunch>
- <args.brunch>/C brunch</args.brunch>
<executable.gzip>gzip</executable.gzip>
<executable.mkdir>cmd</executable.mkdir>
<args.mkdir>/C mkdir</args.mkdir>
- <executable.npm>cmd</executable.npm>
- <args.npm>/C npm</args.npm>
<executable.rmdir>cmd</executable.rmdir>
<args.rm.clean>/C rmdir /S /Q</args.rm.clean>
<executable.shell>cmd</executable.shell>
<fileextension.shell>cmd</fileextension.shell>
<args.shell>/C</args.shell>
+ <executable.node>node.exe</executable.node>
+ <args.npm.full.path>node/npm/bin/npm-cli.js</args.npm.full.path>
+ <args.brunch.full.path>node_modules/brunch/bin/brunch</args.brunch.full.path>
</properties>
</profile>
<profile>
@@ -293,18 +334,17 @@
<properties>
<envClassifier>linux</envClassifier>
<dirsep>/</dirsep>
- <executable.brunch>brunch</executable.brunch>
- <args.brunch></args.brunch>
<executable.gzip>gzip</executable.gzip>
<executable.mkdir>mkdir</executable.mkdir>
<args.mkdir></args.mkdir>
- <executable.npm>npm</executable.npm>
- <args.npm></args.npm>
<executable.rmdir>rm</executable.rmdir>
<args.rm.clean>-rf</args.rm.clean>
<executable.shell>sh</executable.shell>
<fileextension.shell>sh</fileextension.shell>
<args.shell></args.shell>
+ <executable.node>node/node</executable.node>
+ <args.npm.full.path>node/npm/bin/npm-cli.js</args.npm.full.path>
+ <args.brunch.full.path>node_modules/brunch/bin/brunch</args.brunch.full.path>
</properties>
</profile>
</profiles>
http://git-wip-us.apache.org/repos/asf/ambari/blob/ce625503/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index c703bcf..a052e45 100644
--- a/pom.xml
+++ b/pom.xml
@@ -198,8 +198,8 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.0</version>
<configuration>
- <source>1.6</source>
- <target>1.6</target>
+ <source>1.6</source>
+ <target>1.6</target>
</configuration>
</plugin>
<plugin>
@@ -271,7 +271,7 @@
<exclude>**/.gitkeep</exclude>
<exclude>**/.jshintrc</exclude>
<exclude>**/.editorconfig</exclude>
- <!--gitignore content-->
+ <!--gitignore content-->
<exclude>.DS_Store</exclude>
<exclude>**/*.iml</exclude>
<exclude>.classpath</exclude>
@@ -283,14 +283,16 @@
<exclude>.hgignore</exclude>
<exclude>.hgtags</exclude>
+ <!-- Nodejs and npm -->
+ <exclude>ambari-web/node_modules/**</exclude>
+ <exclude>ambari-web/node/**</exclude>
+
<!--Python Mock library (BSD license)-->
<exclude>ambari-common/src/test/python/mock/**</exclude>
<!--Jinja2 library (BSD license)-->
<exclude>ambari-common/src/main/python/ambari_jinja2/**</exclude>
<exclude>ambari-common/src/main/python/jinja2/**</exclude>
- <exclude>ambari-web/node_modules/**</exclude>
-
<!--Contributions-->
<exclude>contrib/ambari-scom/management-pack/Hadoop_MP/**</exclude>
<exclude>contrib/addons/test/dataServices/jmx/data/cluster_configuration.json.nohbase</exclude>
@@ -391,10 +393,10 @@
<fileset>
<directory>${basedir}</directory>
<followSymlinks>false</followSymlinks>
- <includes>
+ <includes>
<include>**/*.pyc</include>
</includes>
- </fileset>
+ </fileset>
</filesets>
</configuration>
</plugin>