Permalink
Browse files

added support for automatically moving the cdnjs files when a release…

… is not -SNAPSHOT
  • Loading branch information...
prb112 committed Dec 1, 2015
1 parent ed0e727 commit 27ed8f5e01b11b74717db573797c00f35e3ca2f5
Showing with 42 additions and 0 deletions.
  1. +17 −0 assembly/deploy-cdnjs.xml
  2. +25 −0 assembly/pom.xml
View
@@ -0,0 +1,17 @@
<project default="manage-cdnjs">
<target name="snapshotstatus">
<condition property="notSnapshot" value="false" else="true">
<matches string="${project.version}" pattern="SNAPSHOT$" />
</condition>
<echo message="This is version - ${project.version}"/>
<echo message="The not snapshot status is - ${notSnapshot}" />
</target>
<target name="manage-cdnjs" if="${notSnapshot}" depends="snapshotstatus">
<copy file="./sdk/com.ibm.sbt.web/src/main/webapp/js/sdk/_layers/sbt-core-dojo-amd.js.uncompressed.js" todir="./assembly/cdnjs" overwrite="true"/>
<copy file="./sdk/com.ibm.sbt.web/src/main/webapp/js/sdk/_layers/sbt-core-dojo-amd.js" todir="./assembly/cdnjs" overwrite="true"/>
<copy file="./sdk/com.ibm.sbt.web/src/main/webapp/js/sdk/_layers/sbt-extra-controls-dojo-amd.js.uncompressed.js" todir="./assembly/cdnjs" overwrite="true"/>
<copy file="./sdk/com.ibm.sbt.web/src/main/webapp/js/sdk/_layers/sbt-extra-controls-dojo-amd.js" todir="./assembly/cdnjs" overwrite="true"/>
</target>
</project>
View
@@ -417,6 +417,31 @@
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.8</version>
<executions>
<!-- Automates the movement of the js files to the approved assembly
location -->
<execution>
<id>move-cdnjs</id>
<!-- phase selected is deploy - ONLY EXECUTED WHEN DEPLOY/INSTALL to Nexus. to debug use clean -->
<phase>deploy</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<ant antfile="deploy-cdnjs.xml" />
<echo message="Finished Calling Target" />
</target>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>

0 comments on commit 27ed8f5

Please sign in to comment.