2010-06-20 5 views

risposta

9

non l'ho testato, ma questo dovrebbe fare quello che stai chiedendo:

jar { 
    from configurations.compile.collect { 
     it.isDirectory() ? it : zipTree(it).matching{exclude{it.name == 'META-INF'}} 
    } 
} 
4

Sì, quanto sopra da TheKaptain funziona tranne che invece di: it.name == ' META-INF ' uso: it.path.contains (' META-INF ').

+1

Dovresti modificare la sua risposta :) –