1

I have a directory with plenty of moduls in it.

Looks like:

C: 

|--Project 

      |----files

            |----Modul1
                    |----FoldersinModuls
            |----Modul2
                    |----FoldersinModuls
            |----Modul3
                    |----FoldersinModuls
            |----Modul4
                    |----FoldersinModuls

I need a list like this: Modul1,Modul2,Modul3,Modul4

But the only thing I get is: C:\Project\files\Modul1,C:\Project\files\Modul2,C:\Project\files\Modul3,C:\Project\files\Modul4

<dirset id="list.moduls" dir="${basedir}" includes="*" excludes=".folder">
</dirset>
<pathconvert pathsep="," property="list.of.moduls" refid="list.moduls">
<mapper type="identity"/> 
</pathconvert>  
<echo message="${list.of.moduls}"/>
BenMorel
  • 34,448
  • 50
  • 182
  • 322
Xref_failed
  • 43
  • 10
  • I Finally solved it using this answer: http://stackoverflow.com/questions/1176071/replacing-characters-in-ant-property > Answer --> In case you want a solution that does use Ant built-ins > only, consider this: – Xref_failed Oct 17 '12 at 14:59

1 Answers1

0

@Jayan i answered it by comment because i had to leave my workplace.

I Finally solved it using this answer:

Replacing characters in Ant property

Answer --> In case you want a solution that does use Ant built-ins only, consider this:

It is btw the only method i found that worked. A direct generation/replacement (as i thought) is not possible.

Community
  • 1
  • 1
Xref_failed
  • 43
  • 10