forked from sakaiproject/sakai
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
git-svn-id: https://source.sakaiproject.org/svn/pack/trunk@88404 66ffb92e-73f9-0310-93c1-f5514f145a0a
- Loading branch information
0 parents
commit 905ff25
Showing
11 changed files
with
943 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
bin | ||
target | ||
m2-target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
bin | ||
target | ||
m2-target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,186 @@ | ||
<?xml version="1.0"?> | ||
<project name="package.binary"> | ||
|
||
<!-- Main target --> | ||
<target name="pack.bin" depends="prep,deploy,delete,licenses,tar,zip,cleanup" /> | ||
|
||
<target name="prep" description="Delete target directories."> | ||
<echo message="[INFO] prep for sakai-bin-${sakai.version} archive creation." /> | ||
<!-- Property check --> | ||
<echo message="basedir=${basedir}" /> | ||
<echo message="sakai.skip.tests=${sakai.skip.tests}" /> | ||
<echo message="sakai.tomcat.version=${sakai.tomcat.version}" /> | ||
<echo message="sakai.version=${sakai.version}" /> | ||
|
||
<echo message="[INFO] clear the deploy area." /> | ||
<delete dir="${basedir}/target/pack" /> | ||
<delete dir="${basedir}/target/pack-stage/" /> | ||
|
||
<echo message="[INFO] Clear out old artifacts." /> | ||
<delete file="${basedir}/sakai-bin-${sakai.version}.tar.gz" /> | ||
<delete file="${basedir}/sakai-bin-${sakai.version}.zip" /> | ||
<delete file="${basedir}/sakai-bin-${sakai.version}.tar.gz.MD5" /> | ||
<delete file="${basedir}/sakai-bin-${sakai.version}.tar.gz.SHA1" /> | ||
<delete file="${basedir}/sakai-bin-${sakai.version}.zip.MD5" /> | ||
<delete file="${basedir}/sakai-bin-${sakai.version}.zip.SHA1" /> | ||
</target> | ||
|
||
<target name="deploy" depends="prep" description="Build and deploy to target directory."> | ||
<echo message="[INFO] build and deploy Sakai artifacts to /target/pack (faux Tomcat deployment)." /> | ||
<exec dir="../../" executable="mvn" failonerror="true"> | ||
<arg value="-Dmaven.tomcat.home=${basedir}/target/pack" /> | ||
<arg value="-Dmaven.test.skip=${sakai.skip.tests}" /> | ||
<!-- | ||
<arg value="-Dkeystore=${keystore}" /> | ||
<arg value="-Dalias=${alias}" /> | ||
<arg value="-Dstorepass=${storepass}" /> | ||
--> | ||
<arg value="clean" /> | ||
<arg value="install" /> | ||
<arg value="sakai:deploy" /> | ||
</exec> | ||
</target> | ||
|
||
<target name="delete" depends="deploy" description="Delete extraneous directories."> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="**/bin" /> | ||
</delete> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="**/target" /> | ||
</delete> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="**/m2-target" /> | ||
</delete> | ||
|
||
<!-- .svn is included in Ant's defaultexcludes so use the defaultexcludes flag. --> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="**/.svn" defaultexcludes="false"/> | ||
</delete> | ||
|
||
<!-- Other /pack-* artifacts --> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="pack*/*.tar.gz" /> | ||
</delete> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="pack*/*.zip" /> | ||
</delete> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="pack*/*.MD5" /> | ||
</delete> | ||
<delete includeemptydirs="true"> | ||
<fileset dir="${basedir}/target/pack/" includes="pack*/*.SHA1" /> | ||
</delete> | ||
</target> | ||
|
||
<target name="licenses" depends="delete" description="Copy licenses to target directory."> | ||
<echo message="[INFO] add third-party licenses." /> | ||
<copy | ||
todir="${basedir}/target/pack/licenses/"> | ||
<fileset | ||
dir="${basedir}/../../reference/licenses"> | ||
<exclude name=".svn/**" /> | ||
<exclude name="CVS/**" /> | ||
</fileset> | ||
</copy> | ||
|
||
<echo message="[INFO] add ECL license." /> | ||
<copy file="${basedir}/../../ECLv2.txt" | ||
tofile="${basedir}/target/pack/ECLv2.txt" | ||
overwrite="true" /> | ||
</target> | ||
|
||
<target name="tar" depends="licenses" description="Tar recursively and create checksums."> | ||
<echo message="[INFO] creating sakai-bin-${sakai.version}.tar.gz." /> | ||
<delete file="sakai-bin-${sakai.version}.tar.gz" /> | ||
<delete file="sakai-bin-${sakai.version}.tar.gz.MD5" /> | ||
<delete file="sakai-bin-${sakai.version}.tar.gz.SHA1" /> | ||
<tar destfile="sakai-bin-${sakai.version}.tar.gz" longfile="gnu" compression="gzip"> | ||
<tarfileset | ||
dir="${basedir}/target/pack/common" | ||
prefix="/common" dirmode="750" | ||
filemode="750" /> | ||
<tarfileset | ||
dir="${basedir}/target/pack/components" | ||
prefix="/components" dirmode="750" | ||
filemode="750" /> | ||
<tarfileset | ||
dir="${basedir}/target/pack/licenses" | ||
prefix="/licenses" dirmode="750" | ||
filemode="750" /> | ||
<tarfileset | ||
dir="${basedir}/target/pack/server" | ||
prefix="/server" dirmode="750" | ||
filemode="750" /> | ||
<tarfileset | ||
dir="${basedir}/target/pack/shared" | ||
prefix="/shared" dirmode="750" | ||
filemode="750" /> | ||
<tarfileset | ||
dir="${basedir}/target/pack/webapps" | ||
prefix="/webapps" dirmode="750" | ||
filemode="750" /> | ||
<tarfileset | ||
dir="${basedir}/target/pack/" | ||
prefix="/"> | ||
<include name="ECLv2.txt" /> | ||
</tarfileset> | ||
</tar> | ||
|
||
<echo message="[INFO] create sakai-bin-${sakai.version}.tar.gz md5 and SHA1 checksums." /> | ||
<checksum file="sakai-bin-${sakai.version}.tar.gz" forceOverwrite="true" /> | ||
<checksum file="sakai-bin-${sakai.version}.tar.gz" forceOverwrite="true" algorithm="SHA1" /> | ||
</target> | ||
|
||
<target name="zip" depends="tar" description="Zip recursively and create checksums."> | ||
<echo message="[INFO] creating sakai-bin-${sakai.version}.zip." /> | ||
<delete file="sakai-bin-${sakai.version}.zip" /> | ||
<delete file="sakai-bin-${sakai.version}.zip.MD5" /> | ||
<delete file="sakai-bin-${sakai.version}.zip.SHA1" /> | ||
<zip destfile="sakai-bin-${sakai.version}.zip" compress="yes"> | ||
<zipfileset | ||
dir="${basedir}/target/pack/common" | ||
prefix="/common" dirmode="750" | ||
filemode="750" /> | ||
<zipfileset | ||
dir="${basedir}/target/pack/components" | ||
prefix="/components" dirmode="750" | ||
filemode="750" /> | ||
<zipfileset | ||
dir="${basedir}/target/pack/licenses" | ||
prefix="/licenses" dirmode="750" | ||
filemode="750" /> | ||
<zipfileset | ||
dir="${basedir}/target/pack/server" | ||
prefix="/server" dirmode="750" | ||
filemode="750" /> | ||
<zipfileset | ||
dir="${basedir}/target/pack/shared" | ||
prefix="/shared" dirmode="750" | ||
filemode="750" /> | ||
<zipfileset | ||
dir="${basedir}/target/pack/webapps" | ||
prefix="/webapps" dirmode="750" | ||
filemode="750" /> | ||
<zipfileset | ||
dir="${basedir}/target/pack/" | ||
prefix="/"> | ||
<include name="ECLv2.txt" /> | ||
</zipfileset> | ||
</zip> | ||
|
||
<echo message="[INFO] create sakai-bin-${sakai.version}.zip md5 and SHA1 checksums." /> | ||
<checksum file="sakai-bin-${sakai.version}.zip" forceOverwrite="true" /> | ||
<checksum file="sakai-bin-${sakai.version}.zip" forceOverwrite="true" algorithm="SHA1" /> | ||
</target> | ||
|
||
<target name="cleanup" depends="zip" description="Move artifacts and delete target directories."> | ||
<echo message="[INFO] moving BIN artifacts to /pack-stage." /> | ||
<move file="${basedir}/target/pack" tofile="${basedir}/target/pack-stage" overwrite="true" /> | ||
|
||
<echo message="[INFO] delete target directories." /> | ||
<delete dir="${basedir}/target/pack/" /> | ||
<delete dir="${basedir}/target/pack-stage/" /> | ||
|
||
<echo message="[INFO] sakai-bin-${sakai.version} archives created." /> | ||
</target> | ||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
<?xml version="1.0"?> | ||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<parent> | ||
<groupId>org.sakaiproject.pack</groupId> | ||
<artifactId>pack</artifactId> | ||
<version>2.9-SNAPSHOT</version> | ||
</parent> | ||
|
||
<name>Sakai Pack Binary</name> | ||
<groupId>org.sakaiproject.pack</groupId> | ||
<artifactId>pack-bin</artifactId> | ||
<version>2.9-SNAPSHOT</version> | ||
<packaging>pom</packaging> | ||
|
||
<organization> | ||
<name>Sakai Project</name> | ||
<url>http://sakaiproject.org/</url> | ||
</organization> | ||
|
||
<issueManagement> | ||
<system>jira</system> | ||
<url>http://jira.sakaiproject.org/browse/SAK</url> | ||
</issueManagement> | ||
|
||
<prerequisites> | ||
<maven>${maven.prereq.version}</maven> | ||
</prerequisites> | ||
|
||
<scm> | ||
<connection>scm:svn:https://source.sakaiproject.org/svn/pack/trunk/pack-bin/</connection> | ||
<developerConnection>scm:svn:https://source.sakaiproject.org/svn/pack/trunk/pack-bin/</developerConnection> | ||
<url>https://source.sakaiproject.org/svn/pack/trunk/pack-bin/</url> | ||
</scm> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-antrun-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>pack-bin-build</id> | ||
<phase>install</phase> | ||
<configuration> | ||
<target> | ||
<property name="basedir" value="${project.basedir}" /> | ||
<property name="localRepo" value="${settings.localRepository}" /> | ||
<property name="sakai.skip.tests" value="${sakai.skip.tests}" /> | ||
<property name="sakai.tomcat.version" value="${sakai.tomcat.version}" /> | ||
<property name="sakai.version" value="${sakai.version}" /> | ||
|
||
<ant antfile="${basedir}/build.xml"> | ||
<target name="pack.bin" /> | ||
</ant> | ||
</target> | ||
</configuration> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
bin | ||
target | ||
m2-target |
Oops, something went wrong.