You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Todd Chambery <tc...@hotmail.com> on 2001/11/01 21:10:07 UTC
"private" targets
Hi all,
I've noticed that, for organization's sake and code reuse, I've created a
lot of "dependent" targets. These are essentially fragments common to other
targets for which it would make sense to run independently.
I'd like to make it so they could only be run when called from within the
buildfile (not when listed on the command line), thereby more tightly
controlling how my buildfile can be used. Is there any facility for doing
this?
thanks,
Todd
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: "private" targets
Posted by T Master <tm...@iknowledgeinc.com>.
Sweeeeeeet
I never knew that. PeterDonald++
:o)
----- Original Message -----
From: "Peter Donald" <do...@apache.org>
To: "Ant Users List" <an...@jakarta.apache.org>
Sent: Thursday, November 01, 2001 3:22 PM
Subject: Re: "private" targets
> No. However in the CVS version of ant if a task does not have
description=""
> attribute it is sorta private. It is not displayed to user when they do a
> "ant -projecthelp"
>
> --
> Cheers,
>
> Pete
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: "private" targets
Posted by Peter Donald <do...@apache.org>.
On Fri, 2 Nov 2001 07:10, Todd Chambery wrote:
> Hi all,
>
> I've noticed that, for organization's sake and code reuse, I've created a
> lot of "dependent" targets. These are essentially fragments common to
> other targets for which it would make sense to run independently.
>
> I'd like to make it so they could only be run when called from within the
> buildfile (not when listed on the command line), thereby more tightly
> controlling how my buildfile can be used. Is there any facility for doing
> this?
No. However in the CVS version of ant if a task does not have description=""
attribute it is sorta private. It is not displayed to user when they do a
"ant -projecthelp"
--
Cheers,
Pete
--------------------------------
These aren't the droids you're
looking for. Move along.
--------------------------------
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: "private" targets
Posted by Mikko Kurki-Suonio <ma...@davisor.com>.
On Thu, 1 Nov 2001, Todd Chambery wrote:
> I'd like to make it so they could only be run when called from within the
> buildfile (not when listed on the command line), thereby more tightly
> controlling how my buildfile can be used. Is there any facility for doing
> this?
Not really.
You can get something like that with "if=", e.g.
<target name="entrypoint">
<property name="entryok" value="true" />
...
</target>
<target name="not_entrypoint" if="entryok">
...
</target>
Not 100% foolproof, though.
//Mikko
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>