You could do something like:
File[] files = new File("src/main/resources/META-INF").listFiles();
WebArchive war = ShrinkWrap.create(WebArchive.class, "test.war");
for (File file : files) {
war.addAsManifestResource(file);
}
war.writeTo(System.out, Formatters.VERBOSE);
Assuming you have the following files in src/main/resources/META-INF:
beans.xml
configuration1.xml
configuration2.xml
... it would output:
test.war:
/META-INF/
/META-INF/beans.xml
/META-INF/configuration2.xml
/META-INF/configuration1.xml
The path passed to the File constructor might need to be adjusted if you have a nested multi-module project.