SHAR composition

Contents
[ Hide Show ]

Overview

shar is valid Unix shell script. This format is mostly outdated. However, you can compose such an archive with Aspose.Zip similarly as other archives.

1try (SharArchive archive = new SharArchive()) {
2    archive.createEntry("alice.txt", new FileInputStream("alice.txt"));
3    archive.createEntry("data.bin", new FileInputStream("block.raw"));
4    archive.save("result.shar");
5} catch (IOException ex) {
6}
Subscribe to Aspose Product Updates

Get monthly newsletters & offers directly delivered to your mailbox.