Skip to content

Instantly share code, notes, and snippets.

@PiotrNowicki
Created June 25, 2012 15:51
Show Gist options
  • Save PiotrNowicki/2989390 to your computer and use it in GitHub Desktop.
Save PiotrNowicki/2989390 to your computer and use it in GitHub Desktop.
Shrinkwrap delete
WebArchive archive = ShrinkWrap.create(WebArchive.class).addPackages(true, "eu.awaketech.mymodule")
.addAsWebInfResource("beans.xml", "beans.xml")
.addAsResource("META-INF/persistence.xml", "META-INF/persistence.xml");
// To remove some package, I need to do:
archive.delete("/WEB-INF/classes/eu/awaketech/mymodule/config");
// Wish I could do:
// - archive.delete(DataSource.class.getPackage());
// - archive.delete(DataSource.class);
@PiotrNowicki
Copy link
Author

Ok, JIRA updated, CLA signed.

Just waiting for @ALRubinger review :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment