Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to exclude from zipgroupfileset?

Tags:

java

jar

ant

I am using ANT 1.7.1 but I am getting an error that exclude is not supported in zipgroupfileset target.

I am trying to do below operation -

<zipgroupfileset >
                <fileset dir="lib">
                <excludes>
         <exclude>META-INF/*.SF</exclude>
         <exclude>META-INF/*.DSA</exclude>
         <exclude>META-INF/*.RSA</exclude>                                       
                </excludes>

            </fileset>
   </zipgroupfileset>

Please help.

Thanks!

like image 673
B Chawla Avatar asked Dec 29 '12 17:12

B Chawla


1 Answers

Accepted answer didn't work for me, I did the following:

    <zipgroupfileset dir="lib" excludes="<jars containing the signatures>"/>
    <zipfileset src="lib/<jar containing the signatures>" excludes="META-INF/*.SF,META-INF/*.DSA"/>

This solution requires you to know which jars has been signed (contains .SF,.DSA,.RSA) files. You'll need a zipfileset for each of those jars.

zipgroupfileset cannot inspect the contents of the jars.

like image 65
levacjeep Avatar answered Nov 13 '22 10:11

levacjeep