Java Mailing List Archive

http://www.ant-tasks.com/

Home » Ant Users List »

env.COMPUTERNAME not working in linux

Ramu Sethu

2008-02-26

Replies: Find Java Web Hosting

Author LoginPost Reply
Hi

We have a build script which runs in both windows and Linux m/c. Recently i
added property to print the computer name of the m/c in which the script
runs.

In windows everything is fine. Ant sets the property to the hostname in
windows. But in Linux it prints the hostname like "${env.COMPUTERNAME}".
Value is not printed.

Is COMPUTERNAME only for windows? Is there any workaround to print the
hostname(Linux)?

We don't make any changes in the ant script when running in Linux.

--
Thank you
Ramu S
©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.