Unable to parse setupCmdLine...

Hi,

I am trying to use the ANT tasks in websphere.  I am trying to get a simple wsListApp working but get the error:

=======
Unable to parse setupCmdLine: null\bin\setupCmdLine.bat (the system cannot find the path specified)
[wsadmin] The java class is not found: com/ibm/ws/bootstrap/WSLauncher
[wsadmin] Java Result: 1
========

My ANT code is as follows (I run it with the ws_ant command).


========
<?xml version="1.0" encoding="UTF-8"?>

<project name="clusterDeployIter1" default="build-all" basedir=".">

<property name="wasHome.dir" value="C:/Progra~1/IBM/Rational/SDP/6.0/runtimes/base_v6"/>


<path id="ws.lib">
            <fileset dir="${wasHome.dir}/lib">
                <include name="*.jar" />
            </fileset>
            <fileset dir="${wasHome.dir}/bin">
                <include name="*.bat" />
            </fileset>
        </path>

     <!-- websphere -->
    <target name="wsListApp">
    <taskdef name="wsListApp" classname="com.ibm.websphere.ant.tasks.ListApplications">
            <classpath refid="ws.lib"/>
        </taskdef>
     <wsListApp
            wasHome="${websphere.home}"
        />
    </target>

                         
  <target name="build-all" depends="wsListApp"/>
</project>
==========

Any ideas on what might be causing this.

TIA.
engdmorrAsked:
Who is Participating?
 
anumalasCommented:
Hi

Remove the line <wsListApp wasHome="${websphere.home}"/>


build.xml should look like bellow.I have tested in my system its workinf fine:

<?xml version="1.0" encoding="UTF-8"?>

<project name="clusterDeployIter1" default="build-all" basedir=".">

<property name="wasHome.dir" value="C:/Progra~1/IBM/Rational/SDP/6.0/runtimes/base_v6"/>


<path id="ws.lib">
            <fileset dir="${wasHome.dir}/lib" includes="*.jar"/>
            <fileset dir="${wasHome.dir}/bin" includes="*.bat" />
               
</path>

     <!-- websphere -->
    <target name="wsListApp">
    <taskdef name="wsListApp" classname="com.ibm.websphere.ant.tasks.ListApplications">
    <classpath refid="ws.lib"/>
        </taskdef>
    </target>

                         
  <target name="build-all" depends="wsListApp"/>
</project>


Hope this will solve your problem :)
0
 
Peter KwanAnalyst ProgrammerCommented:
I am guessing you are having a typo:

<wsListApp wasHome="${websphere.home}"/>

should be

<wsListApp wasHome="${wasHome.dir}"/>
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.