You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by René Scheibe <re...@tngtech.com> on 2010/12/27 14:11:21 UTC

Cleanup Ant "if" task

Some time ago the Ant "if" task implementation was replaced by another
one using a Javascript version.

I was wondering why this is named If-ant.py and not If-ant.js?

The scriptdef of this "if" task in macros.xml could also be cleaned.

 <scriptdef name="if" language="javascript"
classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
src="./If-ant.py">
  <element name="condition"
classname="org.apache.tools.ant.taskdefs.condition.And"/>
  <element name="commands"
classname="org.apache.tools.ant.taskdefs.Sequential"/>
  <element name="else"
classname="org.apache.tools.ant.taskdefs.Sequential"/>
 </scriptdef>

The referenced loaderref "rhino.class.path.loader" is defined nowhere.
The referenced "rhino.class.path" references a Rhino jar file
("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
existing. There is no "extension" folder at all in trunk.
If the classpathref and loaderref is removed, the "if" task is still
working as they are optional. So it looks like a Javascript engine is
included somewhere else.
If also have found framework/base/ant-scripts/if-script.groovy and it
looks like this is not used either.

I would anyway suggest to use ant-contrib which also includes an "if" task.
See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html

Regards
René Scheibe

-- 
René Scheibe * rene.scheibe@tngtech.com
TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterföhring
Geschäftsführer: Henrik Klagges, Gerhard Müller, Christoph Stock
Sitz: Unterföhring * Amtsgericht München * HRB 135082


Re: Cleanup Ant "if" task

Posted by BJ Freeman <bj...@free-man.net>.
I experienced this with the latest trunk compiling with OpenJDK 1.6
the same trunk compiled fine on windows with oracle JDK
https://issues.apache.org/jira/browse/OFBIZ-3993

=========================
BJ Freeman
Strategic Power Office with Supplier Automation  <http://www.businessesnetwork.com/automation/viewforum.php?f=52>
Specialtymarket.com  <http://www.specialtymarket.com/>
Systems Integrator-- Glad to Assist

Chat  Y! messenger: bjfr33man


René Scheibe sent the following on 12/27/2010 5:11 AM:
> Some time ago the Ant "if" task implementation was replaced by another
> one using a Javascript version.
>
> I was wondering why this is named If-ant.py and not If-ant.js?
>
> The scriptdef of this "if" task in macros.xml could also be cleaned.
>
>   <scriptdef name="if" language="javascript"
> classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
> src="./If-ant.py">
>    <element name="condition"
> classname="org.apache.tools.ant.taskdefs.condition.And"/>
>    <element name="commands"
> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>    <element name="else"
> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>   </scriptdef>
>
> The referenced loaderref "rhino.class.path.loader" is defined nowhere.
> The referenced "rhino.class.path" references a Rhino jar file
> ("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
> existing. There is no "extension" folder at all in trunk.
> If the classpathref and loaderref is removed, the "if" task is still
> working as they are optional. So it looks like a Javascript engine is
> included somewhere else.
> If also have found framework/base/ant-scripts/if-script.groovy and it
> looks like this is not used either.
>
> I would anyway suggest to use ant-contrib which also includes an "if" task.
> See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html
>
> Regards
> René Scheibe
>


Re: Cleanup Ant "if" task

Posted by Jacques Le Roux <ja...@les7arts.com>.
Done at r1100795

http://ant-contrib.sourceforge.net/tasks/tasks/index.html

Jacques

From: "Jacques Le Roux" <jl...@les7arts.com>
> OK thanks, makes totaly sense to me
>
> Jacques
>
> From: "René Scheibe" <re...@tngtech.com>
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> No, I haven't changed it. I just proposed to use ant-contrib instead of
>> implementing "if" in OFBiz itself.
>>
>> Regards,
>> René Scheibe
>>
>> On 05/08/2011 10:56 AM, Jacques Le Roux wrote:
>>> I'd like to include ant-contrib in OFBiz and clean macros.xml, have you
>>> something to contribute René?
>>>
>>> Thanks
>>>
>>> Jacques
>>>
>>> From: "Jacques Le Roux" <ja...@les7arts.com>
>>>> I have not looked into details, this has been committed by Adam
>>>> http://markmail.org/message/wnioayvhpqoo6p6u
>>>> Could you please enlighten us Adam?
>>>>
>>>> Thanks
>>>>
>>>> Jacques
>>>>
>>>> René Scheibe wrote:
>>>>> Some time ago the Ant "if" task implementation was replaced by another
>>>>> one using a Javascript version.
>>>>>
>>>>> I was wondering why this is named If-ant.py and not If-ant.js?
>>>>>
>>>>> The scriptdef of this "if" task in macros.xml could also be cleaned.
>>>>>
>>>>> <scriptdef name="if" language="javascript"
>>>>> classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
>>>>> src="./If-ant.py">
>>>>>  <element name="condition"
>>>>> classname="org.apache.tools.ant.taskdefs.condition.And"/>
>>>>>  <element name="commands"
>>>>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>>>>  <element name="else"
>>>>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>>>> </scriptdef>
>>>>>
>>>>> The referenced loaderref "rhino.class.path.loader" is defined nowhere.
>>>>> The referenced "rhino.class.path" references a Rhino jar file
>>>>> ("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
>>>>> existing. There is no "extension" folder at all in trunk.
>>>>> If the classpathref and loaderref is removed, the "if" task is still
>>>>> working as they are optional. So it looks like a Javascript engine is
>>>>> included somewhere else.
>>>>> If also have found framework/base/ant-scripts/if-script.groovy and it
>>>>> looks like this is not used either.
>>>>>
>>>>> I would anyway suggest to use ant-contrib which also includes an "if"
>>>>> task.
>>>>> See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html
>>>>>
>>>>> Regards
>>>>> René Scheibe
>>>>
>>>>
>>>
>>>
>>
>>
>> - -- 
>> René Scheibe * rene.scheibe@tngtech.com * +49-176-62192936
>> TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterföhring
>> Geschäftsführer: Henrik Klagges, Gerhard Müller, Christoph Stock
>> Sitz: Unterföhring * Amtsgericht München * HRB 135082
>> -----BEGIN PGP SIGNATURE-----
>> Version: GnuPG v1.4.11 (GNU/Linux)
>> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>>
>> iEYEARECAAYFAk3Gj1oACgkQUXs9EHvIuCpuEwCeM8z/uU/uxhaAO14vFhDPxy8u
>> NmAAnjHH1wzr4Em5FXPPj92iLzkJXqu2
>> =A/b1
>> -----END PGP SIGNATURE----- 
>
> 



Re: Cleanup Ant "if" task

Posted by Jacques Le Roux <jl...@les7arts.com>.
OK thanks, makes totaly sense to me

Jacques

From: "René Scheibe" <re...@tngtech.com>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> No, I haven't changed it. I just proposed to use ant-contrib instead of
> implementing "if" in OFBiz itself.
>
> Regards,
> René Scheibe
>
> On 05/08/2011 10:56 AM, Jacques Le Roux wrote:
>> I'd like to include ant-contrib in OFBiz and clean macros.xml, have you
>> something to contribute René?
>>
>> Thanks
>>
>> Jacques
>>
>> From: "Jacques Le Roux" <ja...@les7arts.com>
>>> I have not looked into details, this has been committed by Adam
>>> http://markmail.org/message/wnioayvhpqoo6p6u
>>> Could you please enlighten us Adam?
>>>
>>> Thanks
>>>
>>> Jacques
>>>
>>> René Scheibe wrote:
>>>> Some time ago the Ant "if" task implementation was replaced by another
>>>> one using a Javascript version.
>>>>
>>>> I was wondering why this is named If-ant.py and not If-ant.js?
>>>>
>>>> The scriptdef of this "if" task in macros.xml could also be cleaned.
>>>>
>>>> <scriptdef name="if" language="javascript"
>>>> classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
>>>> src="./If-ant.py">
>>>>  <element name="condition"
>>>> classname="org.apache.tools.ant.taskdefs.condition.And"/>
>>>>  <element name="commands"
>>>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>>>  <element name="else"
>>>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>>> </scriptdef>
>>>>
>>>> The referenced loaderref "rhino.class.path.loader" is defined nowhere.
>>>> The referenced "rhino.class.path" references a Rhino jar file
>>>> ("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
>>>> existing. There is no "extension" folder at all in trunk.
>>>> If the classpathref and loaderref is removed, the "if" task is still
>>>> working as they are optional. So it looks like a Javascript engine is
>>>> included somewhere else.
>>>> If also have found framework/base/ant-scripts/if-script.groovy and it
>>>> looks like this is not used either.
>>>>
>>>> I would anyway suggest to use ant-contrib which also includes an "if"
>>>> task.
>>>> See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html
>>>>
>>>> Regards
>>>> René Scheibe
>>>
>>>
>>
>>
>
>
> - -- 
> René Scheibe * rene.scheibe@tngtech.com * +49-176-62192936
> TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterföhring
> Geschäftsführer: Henrik Klagges, Gerhard Müller, Christoph Stock
> Sitz: Unterföhring * Amtsgericht München * HRB 135082
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.11 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iEYEARECAAYFAk3Gj1oACgkQUXs9EHvIuCpuEwCeM8z/uU/uxhaAO14vFhDPxy8u
> NmAAnjHH1wzr4Em5FXPPj92iLzkJXqu2
> =A/b1
> -----END PGP SIGNATURE----- 



Re: Cleanup Ant "if" task

Posted by René Scheibe <re...@tngtech.com>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

No, I haven't changed it. I just proposed to use ant-contrib instead of
implementing "if" in OFBiz itself.

Regards,
René Scheibe

On 05/08/2011 10:56 AM, Jacques Le Roux wrote:
> I'd like to include ant-contrib in OFBiz and clean macros.xml, have you
> something to contribute René?
> 
> Thanks
> 
> Jacques
> 
> From: "Jacques Le Roux" <ja...@les7arts.com>
>> I have not looked into details, this has been committed by Adam
>> http://markmail.org/message/wnioayvhpqoo6p6u
>> Could you please enlighten us Adam?
>>
>> Thanks
>>
>> Jacques
>>
>> René Scheibe wrote:
>>> Some time ago the Ant "if" task implementation was replaced by another
>>> one using a Javascript version.
>>>
>>> I was wondering why this is named If-ant.py and not If-ant.js?
>>>
>>> The scriptdef of this "if" task in macros.xml could also be cleaned.
>>>
>>> <scriptdef name="if" language="javascript"
>>> classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
>>> src="./If-ant.py">
>>>  <element name="condition"
>>> classname="org.apache.tools.ant.taskdefs.condition.And"/>
>>>  <element name="commands"
>>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>>  <element name="else"
>>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>> </scriptdef>
>>>
>>> The referenced loaderref "rhino.class.path.loader" is defined nowhere.
>>> The referenced "rhino.class.path" references a Rhino jar file
>>> ("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
>>> existing. There is no "extension" folder at all in trunk.
>>> If the classpathref and loaderref is removed, the "if" task is still
>>> working as they are optional. So it looks like a Javascript engine is
>>> included somewhere else.
>>> If also have found framework/base/ant-scripts/if-script.groovy and it
>>> looks like this is not used either.
>>>
>>> I would anyway suggest to use ant-contrib which also includes an "if"
>>> task.
>>> See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html
>>>
>>> Regards
>>> René Scheibe
>>
>>
> 
> 


- -- 
René Scheibe * rene.scheibe@tngtech.com * +49-176-62192936
TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterföhring
Geschäftsführer: Henrik Klagges, Gerhard Müller, Christoph Stock
Sitz: Unterföhring * Amtsgericht München * HRB 135082
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk3Gj1oACgkQUXs9EHvIuCpuEwCeM8z/uU/uxhaAO14vFhDPxy8u
NmAAnjHH1wzr4Em5FXPPj92iLzkJXqu2
=A/b1
-----END PGP SIGNATURE-----

Re: Cleanup Ant "if" task

Posted by Jacques Le Roux <ja...@les7arts.com>.
I'd like to include ant-contrib in OFBiz and clean macros.xml, have you something to contribute René?

Thanks

Jacques

From: "Jacques Le Roux" <ja...@les7arts.com>
>I have not looked into details, this has been committed by Adam http://markmail.org/message/wnioayvhpqoo6p6u
> Could you please enlighten us Adam?
>
> Thanks
>
> Jacques
>
> René Scheibe wrote:
>> Some time ago the Ant "if" task implementation was replaced by another
>> one using a Javascript version.
>>
>> I was wondering why this is named If-ant.py and not If-ant.js?
>>
>> The scriptdef of this "if" task in macros.xml could also be cleaned.
>>
>> <scriptdef name="if" language="javascript"
>> classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
>> src="./If-ant.py">
>>  <element name="condition"
>> classname="org.apache.tools.ant.taskdefs.condition.And"/>
>>  <element name="commands"
>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>>  <element name="else"
>> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>> </scriptdef>
>>
>> The referenced loaderref "rhino.class.path.loader" is defined nowhere.
>> The referenced "rhino.class.path" references a Rhino jar file
>> ("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
>> existing. There is no "extension" folder at all in trunk.
>> If the classpathref and loaderref is removed, the "if" task is still
>> working as they are optional. So it looks like a Javascript engine is
>> included somewhere else.
>> If also have found framework/base/ant-scripts/if-script.groovy and it
>> looks like this is not used either.
>>
>> I would anyway suggest to use ant-contrib which also includes an "if" task.
>> See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html
>>
>> Regards
>> René Scheibe
>
>



Re: Cleanup Ant "if" task

Posted by Jacques Le Roux <ja...@les7arts.com>.
I have not looked into details, this has been committed by Adam http://markmail.org/message/wnioayvhpqoo6p6u
Could you please enlighten us Adam?

Thanks

Jacques

René Scheibe wrote:
> Some time ago the Ant "if" task implementation was replaced by another
> one using a Javascript version.
>
> I was wondering why this is named If-ant.py and not If-ant.js?
>
> The scriptdef of this "if" task in macros.xml could also be cleaned.
>
> <scriptdef name="if" language="javascript"
> classpathref="rhino.class.path" loaderref="rhino.class.path.loader"
> src="./If-ant.py">
>  <element name="condition"
> classname="org.apache.tools.ant.taskdefs.condition.And"/>
>  <element name="commands"
> classname="org.apache.tools.ant.taskdefs.Sequential"/>
>  <element name="else"
> classname="org.apache.tools.ant.taskdefs.Sequential"/>
> </scriptdef>
>
> The referenced loaderref "rhino.class.path.loader" is defined nowhere.
> The referenced "rhino.class.path" references a Rhino jar file
> ("${ofbiz.home.dir}/extension/rhino/lib/js-1.7.R1.jar") which is not
> existing. There is no "extension" folder at all in trunk.
> If the classpathref and loaderref is removed, the "if" task is still
> working as they are optional. So it looks like a Javascript engine is
> included somewhere else.
> If also have found framework/base/ant-scripts/if-script.groovy and it
> looks like this is not used either.
>
> I would anyway suggest to use ant-contrib which also includes an "if" task.
> See: http://ant-contrib.sourceforge.net/tasks/tasks/if.html
>
> Regards
> René Scheibe