ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Morten Mortensen <>
Subject RE: echoing filesize
Date Wed, 30 Jul 2003 19:24:37 GMT

Hi David & All,

I have had this #¤*%¤#@&%*@#¤ problem. I have made a tool for creating and
maintaining build-environments in general - I am currently testing it for
MIDP/CLDC, which is a particular trouble-some case. By the way, it also
handles external, pre-obfuscated libraries (ProGuard rocks!) and generates
obfuscated, JAD'ed and JavaDoc'ed results. The internal manifest and the
external JAD-file are generated from the same input. More on this later.

This very, very simple thing I could not find anywhere - "file-size",
"is-file", "is-dir" - stuff like that. Reading file-timestamps could also
come in handy at some point. The missing "file-size" is incredibly painful
when using upload-programs for e.g. Nokia-phones; if the size is wrong, one
must set it in the JAD-file. I believe, that the interpretation of
"MIDlet-Jar-Size" have been relaxed by Sun at some point - perhaps that was
just the data-size, not the jar-size?

I have a couple of Ant-tasks - one of them is a "file-size" task, which I
use for setting "MIDlet-Jar-Size" - see page 3 -

See also -

For the moment, you are free to use the source-code in any way you see fit.

Apparently, no one uses Ant for generating MIDlets... ;-)

Med venlig hilsen 
  Morten Sabroe Mortensen 
  TietoEnator A/S, Ved Lunden 12, 8230 Åbyhøj, Danmark

-----Original Message-----
From: dc []
Sent: 30. juli 2003 12:57
To: 'Ant Users List'
Subject: echoing filesize

Is there a built in ant task that can echo a filesize?
can task output be directed to a variable?

I am trying to create a portable build env that doesn't require external


<property name="filesize" value="... somehow read a file's size" />

<echo file="${MIDlet-Name}.jad" append="false">
	MIDlet-Name: ${MIDlet-Name}


david [dc] collier

Web & Mobile Contents Business Group

  e   |
  v   |  +81(0)90 7414 6107

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message