[pal-cvs 2715] [447] updated target setup shell

Zurück zum Archiv-Index

svnno****@sourc***** svnno****@sourc*****
2007年 8月 5日 (日) 22:51:29 JST


Revision: 447
          http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=pal&view=rev&rev=447
Author:   takeharu
Date:     2007-08-05 22:51:29 +0900 (Sun, 05 Aug 2007)

Log Message:
-----------
updated target setup shell

Modified Paths:
--------------
    pompei/portlets/pompei-core/trunk/build.xml


-------------- next part --------------
Modified: pompei/portlets/pompei-core/trunk/build.xml
===================================================================
--- pompei/portlets/pompei-core/trunk/build.xml	2007-08-04 10:12:51 UTC (rev 446)
+++ pompei/portlets/pompei-core/trunk/build.xml	2007-08-05 13:51:29 UTC (rev 447)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
-<project name="build" default="all" basedir=".">
+<project name="build" default="" basedir=".">
 
   <property name="war.name" value="pompei-core"/>
   <property name="src.main.webapp.webinf.classes" value="${basedir}/src/main/webapp/WEB-INF/classes"/>
@@ -8,23 +8,41 @@
   <property name="target.webapp.webinf.lib" value="${basedir}/target/${war.name}/WEB-INF/lib"/>
   <property name="target.webapp.webinf.classes" value="${basedir}/target/${war.name}/WEB-INF/classes"/>
 
+	<!--
   <property name="shell.cmd" value="sh"/>
   <property name="shell.options" value="-c"/>
-
-  <target name="check.os" 
+  <property name="shell.cmd" value="cmd.exe"/>
+  <property name="shell.options" value="/c"/>
+-->
+  <target name="check.os"
           description="--> Check OS">
     <condition property="isWindows">
       <os family="windows" />
     </condition>
   </target>
 
-  <target name="setup.shell" depends="check.os" if="isWindows"
+
+  <target name="setup.shell"
           description="--> Setup shell parameters">
-    <property name="shell.cmd" value="cmd.exe"/>
+	<condition property="shell.cmd" value="sh">
+      <os family="unix" />
+    </condition>
+	<condition property="shell.options" value="-c">
+      <os family="unix" />
+    </condition>
+	<condition property="shell.cmd" value="cmd.exe">
+      <os family="windows" />
+    </condition>
+	<condition property="shell.options" value="/c">
+      <os family="windows" />
+    </condition>
+<!--
+  	<property name="shell.cmd" value="cmd.exe"/>
     <property name="shell.options" value="/c"/>
+-->
   </target>
 
-  <target name="clean" 
+  <target name="clean"
           description="--> Clean Directories">
     <delete dir="${src.main.webapp.webinf.classes}"/>
     <delete dir="${src.main.webapp.webinf.lib}"/>
@@ -68,12 +86,13 @@
         >
     </replace>
 
+  	<echo>${shell.options}</echo>
     <exec
       executable="${shell.cmd}"
       failonerror="true"
       dir="${basedir}"
       >
-      <arg line="${shell.options} 'mvn install'"/>
+    	<arg line="${shell.options} 'mvn install'"/>
     </exec>
 
     <mkdir dir="${src.main.webapp.webinf.classes}"/>
@@ -114,7 +133,7 @@
     <replace
         file="${basedir}/pom.xml"
         token="&lt;!-- SERVLET DEV: END --&gt;"
-        value="@@@@ SERVLET DEV: END --&gt;" 
+        value="@@@@ SERVLET DEV: END --&gt;"
         >
     </replace>
 
@@ -128,7 +147,7 @@
     <replace
         file="${basedir}/src/main/webapp/WEB-INF/web.xml"
         token="&lt;!-- SERVLET DEV: END --&gt;"
-        value="@@@@ SERVLET DEV: END --&gt;" 
+        value="@@@@ SERVLET DEV: END --&gt;"
         >
     </replace>
 


pal-cvs メーリングリストの案内
Zurück zum Archiv-Index