You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Udo Jüttner <Ud...@impress.com> on 2002/04/24 15:30:28 UTC
Problem with '$' character in file names?!
Hi there,
actually I want to create a jar file by using a fileset which in turn is fed
by a patternset. The situation is like below (ant 1.4.1 on SunOS 5.6 and JDK
1.3.1):
...
<patternset id="include.weblogiccl">
<include name="weblogic/rmi/internal/dgc/DGCServer.class"/>
<include name="weblogic/rmi/internal/dgc/DGCClientImpl$HeartBeat.class"/>
<include name="weblogic/rmi/internal/dgc/DGCReferenceCounter.class"/>
<include name="weblogic/rmi/internal/dgc/DGCClientImpl.class"/>
</patternset>
...
<target name="weblogicSome">
<jar jarfile="${dest.dir}/some.jar">
<fileset dir="${tmp.dir}/some">
<patternset refid="include.weblogiccl"/>
</fileset>
</jar>
</target>
...
Everything works fine, except for that the file with the '$' character in
its name is NOT included into the jar file. Is there a known problem with
any special characters? I also tried to quote the '$' by using '\' - like
one does in UNIX shells.
Any help is welcome. Thanx in advance.
Bye,
Udo Jüttner
Research & Development
Engineering
IMPRESS SOFTWARE AG
Rotenburger Straße 21
30659 Hannover
Phone +49 (0)5 11 - 6 10 71 - 325
Fax +49 (0)5 11 - 6 10 71 - 320
Mobile +49 (0)1 63 - 5 37 10 22
mailto:udo.juettner@IMPRESS.com
http://www.IMPRESS.com
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem with '$' character in file names?!
Posted by stephan beal <st...@wanderinghorse.net>.
On Wednesday 24 April 2002 15:30, Udo Jüttner wrote:
> <include name="weblogic/rmi/internal/dgc/DGCClientImpl$HeartBeat.class"/>
...
> Everything works fine, except for that the file with the '$' character in
> its name is NOT included into the jar file. Is there a known problem with
> any special characters? I also tried to quote the '$' by using '\' - like
> one does in UNIX shells.
> Any help is welcome. Thanx in advance.
That looks like exactly the same problem as the post i just made on ant-devel
about property replacement in general in general. Here the important bit:
Assumption: net.sf.antcontrib.logic.PropExpansionTest is a simple task which
just takes the given character data and prints it out, doing property
replacement if replaceproperties="true".
<taskdef name="propexpand"
classname="net.sf.antcontrib.logic.PropExpansionTest"/>
<property name="whattodrink" value="milk"/>
<propexpand replaceproperties="true">
$foo = "${whattodrink}";
print "foo=$foo\n";
</propexpand>
<propexpand replaceproperties="false">
$foo = "${whattodrink}";
print "foo=$foo\n";
</propexpand>
It produces this output:
property expansion = [true]
text=
foo = "milk";
print "foo=foo\n";
property expansion = [false]
text=
$foo = "${whattodrink}";
print "foo=$foo\n";
Note all the missing dollar signs in the first one.
----- stephan
stephan@einsurance.de - http://www.einsurance.de
Office: +49 (89) 552 92 862 Handy: +49 (179) 211 97 67
"I didn't give in to the Nazis and I won't give in to the bladder."
- The Queen Mum
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem with '$' character in file names?!
Posted by Stefan Bodewig <bo...@apache.org>.
On Wed, 24 Apr 2002, Udo Jüttner <Ud...@impress.com> wrote:
> Everything works fine, except for that the file with the '$'
> character in its name is NOT included into the jar file.
Ant up to 1.4.1 swallows all characters that iimediately follow a $
sign. Escape it with another dollar.
weblogic/rmi/internal/dgc/DGCClientImpl$$HeartBeat.class
and you are done.
This will still work but no longer be necessary in Ant 1.5.
Stefan
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
RE: Problem with '$' character in file names?!
Posted by Ed Mangual <ed...@s1.com>.
I had the same issue and I replaced the $ with an * and it worked.
-----Original Message-----
From: Udo Jüttner [mailto:Udo.Juettner@impress.com]
Sent: Wednesday, April 24, 2002 9:30 AM
To: 'ant-user@jakarta.apache.org'
Subject: Problem with '$' character in file names?!
Hi there,
actually I want to create a jar file by using a fileset which in turn is
fed
by a patternset. The situation is like below (ant 1.4.1 on SunOS 5.6 and
JDK
1.3.1):
...
<patternset id="include.weblogiccl">
<include name="weblogic/rmi/internal/dgc/DGCServer.class"/>
<include
name="weblogic/rmi/internal/dgc/DGCClientImpl$HeartBeat.class"/>
<include name="weblogic/rmi/internal/dgc/DGCReferenceCounter.class"/>
<include name="weblogic/rmi/internal/dgc/DGCClientImpl.class"/>
</patternset>
...
<target name="weblogicSome">
<jar jarfile="${dest.dir}/some.jar">
<fileset dir="${tmp.dir}/some">
<patternset refid="include.weblogiccl"/>
</fileset>
</jar>
</target>
...
Everything works fine, except for that the file with the '$' character
in
its name is NOT included into the jar file. Is there a known problem
with
any special characters? I also tried to quote the '$' by using '\' -
like
one does in UNIX shells.
Any help is welcome. Thanx in advance.
Bye,
Udo Jüttner
Research & Development
Engineering
IMPRESS SOFTWARE AG
Rotenburger Straße 21
30659 Hannover
Phone +49 (0)5 11 - 6 10 71 - 325
Fax +49 (0)5 11 - 6 10 71 - 320
Mobile +49 (0)1 63 - 5 37 10 22
mailto:udo.juettner@IMPRESS.com
http://www.IMPRESS.com
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>