commit 50f3e6b99b2182fe44a7d9d19872a42c8331e31d
Author:     joehni <[email protected]>
AuthorDate: Tue, 19 Feb 2013 20:16:52 +0100
Commit:     joehni <[email protected]>
CommitDate: Tue, 19 Feb 2013 20:16:52 +0100

    Optimize Windows batch.

diff --git a/xsite-distribution/src/assembly/assembly-bin.xml 
b/xsite-distribution/src/assembly/assembly-bin.xml
index 0b7630a..f7b21d3 100644
--- a/xsite-distribution/src/assembly/assembly-bin.xml
+++ b/xsite-distribution/src/assembly/assembly-bin.xml
@@ -9,8 +9,7 @@
       <outputDirectory>/bin</outputDirectory>
       <includes>
         <include>xsite</include>
-        <include>xsite.bat</include>
-        <include>cpappend.bat</include>
+        <include>xsite.cmd</include>
       </includes>
       <fileMode>0774</fileMode>
     </fileSet>
diff --git a/xsite-distribution/src/bin/cpappend.bat 
b/xsite-distribution/src/bin/cpappend.bat
deleted file mode 100755
index 6d13ee0..0000000
--- a/xsite-distribution/src/bin/cpappend.bat
+++ /dev/null
@@ -1,20 +0,0 @@
-@echo off
-rem Adapted from ASF CPAPPEND.BAT
-rem
-rem Copyright 1999-2004 The Apache Software Foundation
-rem 
-rem Licensed under the Apache License, Version 2.0 (the "License");
-rem you may not use this file except in compliance with 
-rem the License.
-rem You may obtain a copy of the License at
-rem 
-rem http://www.apache.org/licenses/LICENSE-2.0
-rem 
-rem Unless required by applicable law or agreed to in writing, 
-rem software distributed under the License is distributed on an 
-rem "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 
-rem OF ANY KIND, either express or implied.
-rem See the License for the specific language governing 
-rem permissions and limitations under the License.
-rem
-set XSITE_CLASSPATH=%XSITE_CLASSPATH%;%1
\ No newline at end of file
diff --git a/xsite-distribution/src/bin/xsite.bat 
b/xsite-distribution/src/bin/xsite.bat
deleted file mode 100755
index 0fa63ed..0000000
--- a/xsite-distribution/src/bin/xsite.bat
+++ /dev/null
@@ -1,9 +0,0 @@
-@echo off
-rem run XSite
-
-set XSITE_CLASSPATH=
-for %%i in (%XSITE_HOME%\lib\*.jar) do call %XSITE_HOME%\bin\cpappend.bat %%i
-
-%JAVA_HOME%\bin\java -classpath %XSITE_CLASSPATH% org.codehaus.xsite.Main %*
-
-
diff --git a/xsite-distribution/src/bin/xsite.cmd 
b/xsite-distribution/src/bin/xsite.cmd
new file mode 100755
index 0000000..66d301d
--- /dev/null
+++ b/xsite-distribution/src/bin/xsite.cmd
@@ -0,0 +1,19 @@
+@echo off
+rem run XSite
+
+if "%OS%"=="Windows_NT" @setlocal
+if "%OS%"=="WINNT" @setlocal
+
+set XSITE_CLASSPATH=
+for %%i in (%XSITE_HOME%\lib\*.jar) do call :CP_append %%i
+
+%JAVA_HOME%\bin\java -classpath %XSITE_CLASSPATH% org.codehaus.xsite.Main %*
+
+if "%OS%"=="Windows_NT" @endlocal
+if "%OS%"=="WINNT" @endlocal
+goto :EOF
+
+
+:CP_append
+       set XSITE_CLASSPATH=%XSITE_CLASSPATH%;%1
+       goto :EOF



Reply via email to