flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cd...@apache.org
Subject git commit: [flex-asjs] [refs/heads/develop] - Added targets for building and deploying Maven artifacts
Date Thu, 13 Nov 2014 15:15:37 GMT
Repository: flex-asjs
Updated Branches:
  refs/heads/develop c27f0207e -> c66025843


Added targets for building and deploying Maven artifacts


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/c6602584
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/c6602584
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/c6602584

Branch: refs/heads/develop
Commit: c66025843981bab9f6e3db28c5bde497cb698ca0
Parents: c27f020
Author: Christofer Dutz <christofer.dutz@codecentric.de>
Authored: Thu Nov 13 16:15:29 2014 +0100
Committer: Christofer Dutz <christofer.dutz@codecentric.de>
Committed: Thu Nov 13 16:15:29 2014 +0100

----------------------------------------------------------------------
 maven.xml                      | 247 ++++++++++++++++++++++++++++++++++++
 maven/flexjs-framework.pom     |  63 +++++++++
 maven/flexjs-js.pom            |  11 ++
 maven/flexjs-jx.pom            |  11 ++
 maven/flexjs-mxmlc-classes.pom |  11 ++
 maven/flexjs-ui.pom            |  11 ++
 6 files changed, 354 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c6602584/maven.xml
----------------------------------------------------------------------
diff --git a/maven.xml b/maven.xml
new file mode 100644
index 0000000..3fa508f
--- /dev/null
+++ b/maven.xml
@@ -0,0 +1,247 @@
+<?xml version="1.0" ?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<project default="install" basedir=".">
+
+    <property name="version" value="0.0.2"/>
+
+    <!-- Set type to RELEASE in order to deploy to the release repo -->
+    <property name="type" value="SNAPSHOT"/>
+
+    <condition property="maven.version"
+               value="${version}"
+               else="${version}-SNAPSHOT">
+        <equals arg1="${type}" arg2="RELEASE"/>
+    </condition>
+
+    <condition property="maven.repositoryId"
+               value="apache.releases.https"
+               else="apache.snapshots.https">
+        <equals arg1="${type}" arg2="RELEASE"/>
+    </condition>
+
+    <condition property="maven.repositoryUrl"
+               value="https://repository.apache.org/service/local/staging/deploy/maven2"
+               else="https://repository.apache.org/content/repositories/snapshots">
+        <equals arg1="${type}" arg2="RELEASE"/>
+    </condition>
+
+    <target name="package">
+        <echo message="Preparing Maven artifacts vor version ${maven.version} ..."/>
+
+        <delete dir="generated/maven"/>
+        <mkdir dir="generated/maven"/>
+
+        <antcall target="-pack-maven-artifact">
+            <param name="moduleName" value="FlexJSJX"/>
+            <param name="artifactName" value="flexjs-jx"/>
+            <param name="fileName" value="frameworks/as/libs/FlexJSJX.swc"/>
+        </antcall>
+
+        <antcall target="-pack-maven-artifact">
+            <param name="moduleName" value="FlexJSUI"/>
+            <param name="artifactName" value="flexjs-ui"/>
+            <param name="fileName" value="frameworks/as/libs/FlexJSUI.swc"/>
+        </antcall>
+
+        <antcall target="-pack-maven-artifact">
+            <param name="moduleName" value="MXMLCClasses"/>
+            <param name="artifactName" value="flexjs-mxmlc-classes"/>
+            <param name="fileName" value="frameworks/as/libs/MXMLCClasses.swc"/>
+        </antcall>
+
+        <copy file="maven/flexjs-js.pom" tofile="generated/maven/flexjs-js.pom">
+            <filterchain>
+                <tokenfilter>
+                    <replacestring from="@VERSION@" to="${maven.version}"/>
+                </tokenfilter>
+            </filterchain>
+        </copy>
+        <!-- Zip up all the JavaScript in one zip archive -->
+        <zip destfile="generated/maven/flexjs-js.jar">
+            <fileset dir="frameworks/js"/>
+        </zip>
+
+        <antcall target="-prepare-maven-pom-artifact">
+            <param name="artifactName" value="flexjs-framework"/>
+        </antcall>
+    </target>
+
+    <target name="install" depends="package, -setup-aether-antlib">
+        <echo message="Installing Maven artifacts ..."/>
+
+        <antcall target="-install-maven-artifact-file-with-sources">
+            <param name="artifactName" value="flexjs-jx"/>
+            <param name="artifactExtension" value="swc"/>
+        </antcall>
+
+        <antcall target="-install-maven-artifact-file-with-sources">
+            <param name="artifactName" value="flexjs-ui"/>
+            <param name="artifactExtension" value="swc"/>
+        </antcall>
+
+        <antcall target="-install-maven-artifact-file-with-sources">
+            <param name="artifactName" value="flexjs-mxmlc-classes"/>
+            <param name="artifactExtension" value="swc"/>
+        </antcall>
+
+        <antcall target="-install-maven-artifact-file">
+            <param name="artifactName" value="flexjs-js"/>
+            <param name="artifactExtension" value="jar"/>
+        </antcall>
+
+        <antcall target="-install-maven-artifact-pom">
+            <param name="artifactName" value="flexjs-framework"/>
+        </antcall>
+    </target>
+
+    <target name="deploy" depends="install">
+        <echo message="Deploying Maven artifacts to repository with id ${maven.repositoryId}
and url ${maven.repositoryUrl} ..."/>
+
+        <antcall target="-deploy-maven-artifact-file-with-sources">
+            <param name="artifactName" value="flexjs-jx"/>
+        </antcall>
+
+        <antcall target="-deploy-maven-artifact-file-with-sources">
+            <param name="artifactName" value="flexjs-ui"/>
+        </antcall>
+
+        <antcall target="-deploy-maven-artifact-file-with-sources">
+            <param name="artifactName" value="flexjs-mxmlc-classes"/>
+        </antcall>
+
+        <antcall target="-deploy-maven-artifact-file">
+            <param name="artifactName" value="flexjs-js"/>
+        </antcall>
+
+        <antcall target="-deploy-maven-artifact-pom">
+            <param name="artifactName" value="flexjs-framework"/>
+        </antcall>
+    </target>
+
+    <!--
+
+        Internal helper targets.
+
+    -->
+
+    <target name="-setup-aether-antlib">
+        <mkdir dir="utils"/>
+        <get src="http://search.maven.org/remotecontent?filepath=org/eclipse/aether/aether-ant-tasks/1.0.0.v20140518/aether-ant-tasks-1.0.0.v20140518-uber.jar"
+             dest="utils/aether-ant-tasks-uber.jar" verbose="true" skipexisting="true"/>
+        <fail message="Checksum mismatch for 'antlib/aether-ant-tasks-uber.jar'. Please
delete it and rerun ant to redownload.">
+            <condition>
+                <not>
+                    <checksum file="utils/aether-ant-tasks-uber.jar" algorithm="SHA"
+                              property="95dadd03392a75564904da45108cf048abe6e5bb" verifyproperty="checksum.matches"/>
+                </not>
+            </condition>
+        </fail>
+        <!-- Setup the maven-ant-tasks. -->
+        <path id="aether-ant-tasks.classpath" path="utils/aether-ant-tasks-uber.jar" />
+        <typedef resource="org/eclipse/aether/ant/antlib.xml"
+                 uri="antlib:org.eclipse.aether.ant"
+                 classpathref="aether-ant-tasks.classpath" />
+    </target>
+
+    <target name="-pack-maven-artifact">
+        <echo message="Packing module ${moduleName} as Maven artifact ${artifactName}"/>
+        <copy file="maven/${artifactName}.pom" tofile="generated/maven/${artifactName}.pom">
+            <filterchain>
+                <tokenfilter>
+                    <replacestring from="@VERSION@" to="${maven.version}"/>
+                </tokenfilter>
+            </filterchain>
+        </copy>
+        <copy file="${fileName}" tofile="generated/maven/${artifactName}.swc"/>
+        <zip destfile="generated/maven/${artifactName}-sources.jar">
+            <fileset dir="frameworks/as/projects/${moduleName}/src"/>
+            <!--fileset dir="${moduleName}/generated/src"/-->
+        </zip>
+    </target>
+
+    <target name="-prepare-maven-pom-artifact">
+        <echo message="Preparing Maven pom artifact ${artifactName}"/>
+        <copy file="maven/${artifactName}.pom" tofile="generated/maven/${artifactName}.pom">
+            <filterchain>
+                <tokenfilter>
+                    <replacestring from="@VERSION@" to="${maven.version}"/>
+                </tokenfilter>
+            </filterchain>
+        </copy>
+    </target>
+
+    <target name="-install-maven-artifact-pom" depends="-setup-aether-antlib"
+            xmlns:artifact="antlib:org.eclipse.aether.ant">
+        <echo message="Installing Pom: ${artifactName}"/>
+        <artifact:install>
+            <artifact:pom file="generated/maven/${artifactName}.pom"/>
+        </artifact:install>
+    </target>
+
+    <target name="-install-maven-artifact-file" depends="-setup-aether-antlib"
+            xmlns:artifact="antlib:org.eclipse.aether.ant">
+        <echo message="Installing File: ${artifactName}"/>
+        <artifact:install>
+            <artifact:pom file="generated/maven/${artifactName}.pom"/>
+            <artifact:artifact file="generated/maven/${artifactName}.${artifactExtension}"/>
+        </artifact:install>
+    </target>
+
+    <target name="-install-maven-artifact-file-with-sources" depends="-setup-aether-antlib"
+            xmlns:artifact="antlib:org.eclipse.aether.ant">
+        <echo message="Installing File: ${artifactName}"/>
+        <artifact:install>
+            <artifact:pom file="generated/maven/${artifactName}.pom"/>
+            <artifact:artifact file="generated/maven/${artifactName}.${artifactExtension}"/>
+            <artifact:artifact file="generated/maven/${artifactName}-sources.jar" classifier="sources"/>
+        </artifact:install>
+    </target>
+
+    <target name="-deploy-maven-artifact-pom" depends="-setup-aether-antlib"
+            xmlns:artifact="antlib:org.eclipse.aether.ant">
+        <echo message="Deploying Pom: ${artifactName} to ${maven.repositoryUrl}"/>
+        <artifact:deploy>
+            <artifact:remoterepo id="${maven.repositoryId}" url="${maven.repositoryUrl}"/>
+            <artifact:pom file="generated/maven/${artifactName}.pom"/>
+        </artifact:deploy>
+    </target>
+
+    <target name="-deploy-maven-artifact-file" depends="-setup-aether-antlib"
+            xmlns:artifact="antlib:org.eclipse.aether.ant">
+        <echo message="Deploying File: ${artifactName} to ${maven.repositoryUrl}"/>
+        <artifact:deploy>
+            <artifact:remoterepo id="${maven.repositoryId}" url="${maven.repositoryUrl}"/>
+            <artifact:pom file="generated/maven/${artifactName}.pom"/>
+            <artifact:artifact file="generated/maven/${artifactName}.${artifactExtension}"/>
+        </artifact:deploy>
+    </target>
+
+    <target name="-deploy-maven-artifact-file-with-sources" depends="-setup-aether-antlib"
+            xmlns:artifact="antlib:org.eclipse.aether.ant">
+        <echo message="Deploying File: ${artifactName} to ${maven.repositoryUrl}"/>
+        <artifact:deploy>
+            <artifact:remoterepo id="${maven.repositoryId}" url="${maven.repositoryUrl}"/>
+            <artifact:pom file="generated/maven/${artifactName}.pom"/>
+            <artifact:artifact file="generated/maven/${artifactName}.${artifactExtension}"/>
+            <artifact:artifact file="generated/maven/${artifactName}-sources.jar" classifier="sources"/>
+        </artifact:deploy>
+    </target>
+
+</project>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c6602584/maven/flexjs-framework.pom
----------------------------------------------------------------------
diff --git a/maven/flexjs-framework.pom b/maven/flexjs-framework.pom
new file mode 100644
index 0000000..c5d0039
--- /dev/null
+++ b/maven/flexjs-framework.pom
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache</groupId>
+        <artifactId>apache</artifactId>
+        <version>14</version>
+    </parent>
+
+    <groupId>org.apache.flex.framework.flexjs</groupId>
+    <artifactId>flexjs-framework</artifactId>
+    <version>@VERSION@</version>
+    <packaging>pom</packaging>
+
+    <name>Apache FlexJS Framework</name>
+    <description>The Apache FlexJS Framework</description>
+
+    <mailingLists>
+        <mailingList>
+            <name>Apache Flex User List</name>
+            <subscribe>users-subscribe@flex.apache.org</subscribe>
+            <unsubscribe>users-unsubscribe@flex.apache.org</unsubscribe>
+            <post>users@flex.apache.org</post>
+            <archive>http://mail-archives.apache.org/mod_mbox/flex-users/</archive>
+        </mailingList>
+    </mailingLists>
+
+    <scm>
+        <connection>scm:svn:https://git-wip-us.apache.org/repos/asf/flex-falcon.git</connection>
+        <developerConnection>scm:svn:https://git-wip-us.apache.org/repos/asf/flex-falcon.git</developerConnection>
+        <url>https://git-wip-us.apache.org/repos/asf/flex-falcon.git</url>
+    </scm>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.flex.framework.flexjs</groupId>
+            <artifactId>flexjs-jx</artifactId>
+            <version>@VERSION@</version>
+            <type>swc</type>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.flex.framework.flexjs</groupId>
+            <artifactId>flexjs-ui</artifactId>
+            <version>@VERSION@</version>
+            <type>swc</type>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.flex.framework.flexjs</groupId>
+            <artifactId>flexjs-mxmlc-classes</artifactId>
+            <version>@VERSION@</version>
+            <type>swc</type>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.flex.framework.flexjs</groupId>
+            <artifactId>flexjs-js</artifactId>
+            <version>@VERSION@</version>
+            <type>jar</type>
+        </dependency>
+    </dependencies>
+
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c6602584/maven/flexjs-js.pom
----------------------------------------------------------------------
diff --git a/maven/flexjs-js.pom b/maven/flexjs-js.pom
new file mode 100644
index 0000000..87c8aaf
--- /dev/null
+++ b/maven/flexjs-js.pom
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+    <modelVersion>4.0.0</modelVersion>
+
+    <groupId>org.apache.flex.framework.flexjs</groupId>
+    <artifactId>flexjs-js</artifactId>
+    <version>@VERSION@</version>
+    <packaging>jar</packaging>
+
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c6602584/maven/flexjs-jx.pom
----------------------------------------------------------------------
diff --git a/maven/flexjs-jx.pom b/maven/flexjs-jx.pom
new file mode 100644
index 0000000..ccae6f3
--- /dev/null
+++ b/maven/flexjs-jx.pom
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+    <modelVersion>4.0.0</modelVersion>
+
+    <groupId>org.apache.flex.framework.flexjs</groupId>
+    <artifactId>flexjs-jx</artifactId>
+    <version>@VERSION@</version>
+    <packaging>swc</packaging>
+
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c6602584/maven/flexjs-mxmlc-classes.pom
----------------------------------------------------------------------
diff --git a/maven/flexjs-mxmlc-classes.pom b/maven/flexjs-mxmlc-classes.pom
new file mode 100644
index 0000000..40fa9cc
--- /dev/null
+++ b/maven/flexjs-mxmlc-classes.pom
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+    <modelVersion>4.0.0</modelVersion>
+
+    <groupId>org.apache.flex.framework.flexjs</groupId>
+    <artifactId>flexjs-mxmlc-classes</artifactId>
+    <version>@VERSION@</version>
+    <packaging>swc</packaging>
+
+</project>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c6602584/maven/flexjs-ui.pom
----------------------------------------------------------------------
diff --git a/maven/flexjs-ui.pom b/maven/flexjs-ui.pom
new file mode 100644
index 0000000..aba6615
--- /dev/null
+++ b/maven/flexjs-ui.pom
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+    <modelVersion>4.0.0</modelVersion>
+
+    <groupId>org.apache.flex.framework.flexjs</groupId>
+    <artifactId>flexjs-ui</artifactId>
+    <version>@VERSION@</version>
+    <packaging>swc</packaging>
+
+</project>


Mime
View raw message