ANT-taget imported via ant.importBuild should hide tasknames with "-" as the first charachter

If I import these two tasks into gradle via ant.importBuild

<target name="-cleanup-js">
        <delete>
           ...
        </delete>
    </target>
      <target name="make-js" depends="-cleanup-js">
        <exec executable="${dart2js.exec}" failonerror="true">
          ...
        </exec>
    </target>

Gradle should only show “make-js” on gradle tasks. -cleanup-js should be hidden.

I can’t seem to reproduce this. Which Gradle version are you using?

With 1.8 I see the expected output:

gradle tasks

Other tasks
-----------
make-js

gradle tasks --all

Other tasks
-----------
make-js
    -cleanup-js

I guess that ‘-cleanup-js’ is hidden here as per the normal Gradle rules for showing/hiding tasks, not because it’s a private Ant target.

That’s correct. I was just about to add that information. I am not aware of a way to hide tasks with a specific naming pattern.

Thinking more about this, private Ant targets should normally be depended-on by some other target (else why have them). So unless our Ant import adds a description (does it?), the desired behavior should emerge automatically.

Hmmm - I switched to 1.8 and everything seems to be OK now. Thanks for your help!