activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r590829 - in /activemq/activemq-dotnet/Apache.NMS/trunk: lib/ nant-common.xml nant.build src/main/csharp/CommonAssemblyInfo.cs src/test/csharp/CommonAssemblyInfo.cs
Date Wed, 31 Oct 2007 21:05:50 GMT
Author: chirino
Date: Wed Oct 31 14:05:49 2007
New Revision: 590829

URL: http://svn.apache.org/viewvc?rev=590829&view=rev
Log:
Adding some tasks that simulate the maven repo download process

Removed:
    activemq/activemq-dotnet/Apache.NMS/trunk/lib/
Modified:
    activemq/activemq-dotnet/Apache.NMS/trunk/nant-common.xml
    activemq/activemq-dotnet/Apache.NMS/trunk/nant.build
    activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/CommonAssemblyInfo.cs
    activemq/activemq-dotnet/Apache.NMS/trunk/src/test/csharp/CommonAssemblyInfo.cs

Modified: activemq/activemq-dotnet/Apache.NMS/trunk/nant-common.xml
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS/trunk/nant-common.xml?rev=590829&r1=590828&r2=590829&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS/trunk/nant-common.xml (original)
+++ activemq/activemq-dotnet/Apache.NMS/trunk/nant-common.xml Wed Oct 31 14:05:49 2007
@@ -39,7 +39,70 @@
   <property name="current.build.framework" value="${framework::get-target-framework()}"/>
   <property name="current.build.defines"   value="${build.defines}" />
 
-  <!-- Helper targets used to enable build configurations -->
+  <!-- Figure out the user's HOME directory --> 
+  <property name="user.home" value="${environment::get-variable('HOME')}"
+            if="${environment::variable-exists('HOME')}"
+            unless="${property::exists('user.home')}"/>
+  <fail message="The HOME environment is not defined.  Please set it to your home directory."
+            unless="${property::exists('user.home')}"/>
+            
+  <!-- Figure out the NANT repositories--> 
+  <property name="nant.repo" value="${environment::get-variable('NANT_REPO')}"
+            if="${environment::variable-exists('NANT_REPO')}"
+            unless="${property::exists('nant.repo')}"/>
+  <property name="nant.local.repo" value="${user.home}/.nant/repository"
+            unless="${property::exists('nant.local.repo')}"/>
+
+  <property name="nant.remote.repo" value="${environment::get-variable('NANT_REMOTE_REPO')}"
+                      if="${environment::variable-exists('NANT_REMOTE_REPO')}"
+                      unless="${property::exists('nant.remote.repo')}"/>             
        
+  <property name="nant.remote.repo" value="http://people.apache.org/~chirino/nant-repo"
+          unless="${property::exists('nant.remote.repo')}"/>
+          
+  <!-- Nant Repo Tasks -->
+  <target name="repo-download" description="Download a dependency from the remote repo
to the local repo">
+    <fail message="The repo.task.artifact variable has not been set.  Please set it before
you call this task." unless="${property::exists('repo.task.artifact')}"/>
+
+    <property name="repo.task.src" value="${nant.remote.repo}/${repo.task.artifact}"/>
  
+    <property name="repo.task.dest" value="${nant.local.repo}/${repo.task.artifact}"/>
  
+
+    <property name="repo.task.download" value="false"/>   
+    <if test="${not file::exists(repo.task.dest)}">
+      <property name="repo.task.download" value="true"/>   
+    </if>
+    
+    <if test="${file::exists(repo.task.dest)}">
+      <!-- TODO: we could also download if the file is a SNAPSHOT and is stale -->
+      <property name="repo.task.download" value="false"/>   
+      <echo message="Artifact: ${nant.remote.repo}/${repo.task.artifact} is up to date."/>
+    </if>
+    
+    <if test="${repo.task.download}">
+      <echo message="Downloading artifact: ${repo.task.src}"/>
+      <mkdir dir="${directory::get-parent-directory(repo.task.dest)}" />
+      <get src="${repo.task.src}" dest="${repo.task.dest}"/>
+    </if>   
+  </target>
+  
+  <target name="repo-install" description="Install a dependency to the local repo">
+    <fail message="The repo.task.artifact variable has not been set.  Please set it before
you call this task." unless="${property::exists('repo.task.artifact')}"/>
+    <fail message="The repo.task.src variable has not been set.  Please set it before
you call this task." unless="${property::exists('repo.task.src')}"/>
+        
+    <property name="repo.task.dest" value="${nant.local.repo}/${repo.task.artifact}"/>
  
+    <copy file="${repo.task.src}" tofile="${nant.local.repo}/${repo.task.dest}"/> 
  
+  </target>
+  
+  <script language="C#" prefix="test" >
+    <code><![CDATA[
+       [Function("test-func")]       
+       public static string Testfunc(  ) {
+            return "some result !!!!!!!!";
+       }
+    ]]></code>
+  </script>
+  <echo message='${test::test-func()}'/>
+  
+<!-- Helper targets used to enable build configurations -->
   <target name="set-noskip-configuration" description="Disable skiping builds">
     <property name="project.noskip"         value="true" />
   </target>

Modified: activemq/activemq-dotnet/Apache.NMS/trunk/nant.build
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS/trunk/nant.build?rev=590829&r1=590828&r2=590829&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS/trunk/nant.build (original)
+++ activemq/activemq-dotnet/Apache.NMS/trunk/nant.build Wed Oct 31 14:05:49 2007
@@ -30,8 +30,14 @@
            value="Apache NMS Class Library"/>
   <property name="project.description"
            value="Apache NMS (.Net Messaging Library): An abstract interface to Message Oriented
Middleware (MOM) providers"/>
+  
+  <property name="nunit.dll" value="org.nunit/nunit/2.2.8/all/nunit.framework.dll"/>
   
 
   <target name="dependency-init" description="Initializes build dependencies">
+  
+    <property name="repo.task.artifact" value="${nunit.dll}"/>    
+    <call target="repo-download"/>
+  
   	<assemblyfileset failonempty="true" id="dependencies">
       <include name="mscorlib.dll" asis="true"/>
       <include name="System.dll" asis="true"/>
@@ -41,7 +47,7 @@
       <include name="mscorlib.dll" asis="true"/>
       <include name="System.dll" asis="true"/>
       <include name="${build.bin.dir}/${project.name}.dll"/>
-      <include name="${lib.dir}/all/nunit/nunit.framework.dll"/>
+      <include name="${nant.local.repo}/${nunit.dll}"/>
   	</assemblyfileset>  
   </target>
   

Modified: activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/CommonAssemblyInfo.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/CommonAssemblyInfo.cs?rev=590829&r1=590828&r2=590829&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/CommonAssemblyInfo.cs (original)
+++ activemq/activemq-dotnet/Apache.NMS/trunk/src/main/csharp/CommonAssemblyInfo.cs Wed Oct
31 14:05:49 2007
@@ -2,21 +2,20 @@
 using System.Reflection;
 using System.Runtime.InteropServices;
 
-//------------------------------------------------------------------------------
-// <auto-generated>
-//     This code was generated by a tool.
-//     Runtime Version:2.0.50727.832
-//
-//     Changes to this file may cause incorrect behavior and will be lost if
-//     the code is regenerated.
-// </auto-generated>
-//------------------------------------------------------------------------------
+// ------------------------------------------------------------------------------
+//  <autogenerated>
+//      This code was generated by a tool.
+//      Mono Runtime Version: 2.0.50727.42
+// 
+//      Changes to this file may cause incorrect behavior and will be lost if 
+//      the code is regenerated.
+//  </autogenerated>
+// ------------------------------------------------------------------------------
 
 [assembly: ComVisibleAttribute(false)]
 [assembly: CLSCompliantAttribute(true)]
 [assembly: AssemblyTitleAttribute("Apache NMS Class Library")]
-[assembly: AssemblyDescriptionAttribute("Apache NMS (.Net Messaging Library): An abstract
interface to Message Oriented Mi" +
-    "ddleware (MOM) providers")]
+[assembly: AssemblyDescriptionAttribute("Apache NMS (.Net Messaging Library): An abstract
interface to Message Oriented Middleware (MOM) providers")]
 [assembly: AssemblyConfigurationAttribute("SNAPSHOT")]
 [assembly: AssemblyCompanyAttribute("http://activemq.apache.org/nms")]
 [assembly: AssemblyProductAttribute("Apache NMS Class Library")]

Modified: activemq/activemq-dotnet/Apache.NMS/trunk/src/test/csharp/CommonAssemblyInfo.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS/trunk/src/test/csharp/CommonAssemblyInfo.cs?rev=590829&r1=590828&r2=590829&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS/trunk/src/test/csharp/CommonAssemblyInfo.cs (original)
+++ activemq/activemq-dotnet/Apache.NMS/trunk/src/test/csharp/CommonAssemblyInfo.cs Wed Oct
31 14:05:49 2007
@@ -2,21 +2,20 @@
 using System.Reflection;
 using System.Runtime.InteropServices;
 
-//------------------------------------------------------------------------------
-// <auto-generated>
-//     This code was generated by a tool.
-//     Runtime Version:2.0.50727.832
-//
-//     Changes to this file may cause incorrect behavior and will be lost if
-//     the code is regenerated.
-// </auto-generated>
-//------------------------------------------------------------------------------
+// ------------------------------------------------------------------------------
+//  <autogenerated>
+//      This code was generated by a tool.
+//      Mono Runtime Version: 2.0.50727.42
+// 
+//      Changes to this file may cause incorrect behavior and will be lost if 
+//      the code is regenerated.
+//  </autogenerated>
+// ------------------------------------------------------------------------------
 
 [assembly: ComVisibleAttribute(false)]
 [assembly: CLSCompliantAttribute(true)]
 [assembly: AssemblyTitleAttribute("Apache NMS Class Library")]
-[assembly: AssemblyDescriptionAttribute("Apache NMS (.Net Messaging Library): An abstract
interface to Message Oriented Mi" +
-    "ddleware (MOM) providers")]
+[assembly: AssemblyDescriptionAttribute("Apache NMS (.Net Messaging Library): An abstract
interface to Message Oriented Middleware (MOM) providers")]
 [assembly: AssemblyConfigurationAttribute("SNAPSHOT")]
 [assembly: AssemblyCompanyAttribute("http://activemq.apache.org/nms")]
 [assembly: AssemblyProductAttribute("Apache NMS Class Library")]



Mime
View raw message