Thanks Brian,
  Yes, I agree with you.   I can understand why it is happening.  I
couldn't tell you why installanywhere does it the way it does.  But, if
that xml is allowed to be changed, then it breaks the compile.   So, it
is a problem.

But, I have figured out the solution.   I can use the 'replace' and
'fixcrlf' tasks to fix the file after the xmltask completes:

    <fixcrlf srcdir="." includes="tmp.iap_xml" eol="lf" eof="remove"/>
    <replace file="tmp.iap_xml" token="&lt;string/&gt;"
value="&lt;string&gt;&lt;![CDATA[]]&gt;&lt;/string&gt;"/>


Thanks for the help.

-Jeff



-----Original Message-----
From: Brian Agnew [mailto:br...@oopsconsultancy.com] 
Sent: Tuesday, March 10, 2009 2:34 PM
To: Tresselt, Jeffrey A
Cc: Mark Coffin; xmltask-users@lists.sourceforge.net
Subject: Re: [Xmltask-users] xmltask is putting DOS line endings on
every lineof the output xml file....

Hi -

The linefeed issue sounds rather peculiar. I will have a look at that.

wrt. the empty strings, <string><![CDATA[]]></string> is being converted
to <string/> by the round tripping of the XML through file->DOM->file
conversion.

<string><![CDATA[]]></string> is (I suspect) equivalent to
<string></string> and thus to <string/> so I'm not surprised that this
occurs. I'm not sure that InstallAnywhere is really doing the right
thing
?

Brian

On Tue, March 10, 2009 18:28, Tresselt, Jeffrey A wrote:
> Great, thanks Mark.
>
>
>
> That will work for question #1...   Which, unfortunately, was not
really
> a problem.   InstallAnywhere does not have a problem with the file
after
> the line endings have changed.
>
>
>
> However, for #2, the fact that all of the empty string declarations
are
> being converted into '<string/>' sections is causing problems.   The
> InstallAnywhere project compiler fails to compile the project because
of
> this......
>
>
>
> I was thinking I could use the normal ant 'replace' or 'replaceregexp'
> task to update the file after running xmltask, but the both the
> 'replace' and 'replaceregexp' tasks do not allow the '<' character to
be
> in the strings.
>
>
>
> So, I am still working on it.
>
>
>
> Thanks again,
>
>   -Jeff
>
>
>
>
>
> Jeff Tresselt
>
> CA
>
> Senior Software Engineer
>
> tel: +1 630 505 6000 Ext: 46216
>
> jeffrey.tress...@ca.com <mailto:jeffrey.tress...@ca.com>
>
>
>
>
>
> From: Mark Coffin [mailto:mcof...@aalsolutions.com]
> Sent: Tuesday, March 10, 2009 1:17 PM
> To: Tresselt, Jeffrey A; xmltask-users@lists.sourceforge.net
> Subject: RE: [Xmltask-users] xmltask is putting DOS line endings on
> every lineof the output xml file....
>
>
>
> Hi Jeff,
>
>
>
> You can use one of FixCRLF standard ant tasks to correct this.
>
>
>
> http://ant.apache.org/manual/CoreTasks/fixcrlf.html
>
>
>
>
>
>
>
>    Mark Coffin
>    mcof...@aalsolutions.com
>    Phone: 905.632.0864
>    1.800.668.8486
>    Fax: 905.632.2605
>    www.aalsolutions.com
>
> ________________________________
>
> From: Tresselt, Jeffrey A [mailto:jeffrey.tress...@ca.com]
> Sent: March 10, 2009 1:44 PM
> To: xmltask-users@lists.sourceforge.net
> Subject: [Xmltask-users] xmltask is putting DOS line endings on every
> lineof the output xml file....
>
>
>
> I am trying to use xmltask to update the version number in an
> InstallAnywhere project file (which is in xml format).
>
>
>
> The update of the version number is successful, but I have two
problems
> with the output xml file.
>
>
>
> 1.    The input xml file is in unix file format, but the output file
has
> '^M' DOS line ending inserted on every line.   Is there an easy way to
> prevent this from happening....
>
>
>
> 2.    In the input file, there are a few empty strings that are
getting
> converted, but they should not be touched.
>
>
>
> Input file contains:
>
>
>
>       <property name="splashScreenGUITitle">
>
>             <string><![CDATA[]]></string>
>
>       </property>
>
>
>
> Output file gets:
>
>
>
>       <property name="splashScreenGUITitle">
>
>             <string/>
>
>       </property>
>
>
>
> Is there an easy way to prevent this from happening, so the output xml
> is exactly the same as the input xml.....?
>
>
>
> Thanks for any help,
>
>  -Jeff
>
>
>
>
>
> Jeff Tresselt
>
> CA
>
> Senior Software Engineer
>
> jeffrey.tress...@ca.com <mailto:jeffrey.tress...@ca.com>
>
>
>
>
>
>
>
>
>
> ****** CONFIDENTIALITY NOTICE ******
>
> NOTICE: This e-mail message and all attachments transmitted with it
may
> contain legally privileged and confidential information intended
solely
> for the use of the addressee. If the reader of this message is not the
> intended recipient, you are hereby notified that any reading,
> dissemination, distribution, copying, or other use of this message or
> its attachments is strictly prohibited. If you have received this
> message in error, please notify the sender immediately and delete this
> message from your system. Thank you.
>
>
------------------------------------------------------------------------
------
> _______________________________________________
> Xmltask-users mailing list
> Xmltask-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/xmltask-users
>


-- 
Brian Agnew                  http://www.oopsconsultancy.com
OOPS Consultancy Ltd
Tel: +44 (0)7720 397526
Fax: +44 (0)20 8682 0012



------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Xmltask-users mailing list
Xmltask-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xmltask-users

Reply via email to