talira

tar (Haskell)

Read, write and manipulate .tar archives in Haskell

open sourceBSD-3-Clausefree

tar is a Haskell library for working with .tar archives: it reads and writes the common variants (V7, POSIX USTAR and GNU), packs and unpacks portable archives, and gives random access to archive contents through an index. Originally by Bjorn Bringert and Duncan Coutts, it lives in the haskell GitHub organisation.

Problems it solves

  • create a tar archive from Haskell
  • extract a .tar file in a Haskell program
  • read one file from a tarball without unpacking it in Haskell

Features

  • read and write V7, USTAR and GNU tar formats
  • pack and unpack portable archives
  • indexed random access to entries

Limitations

  • Doesn't preserve file ownership or exact permissions, so it suits distribution rather than backups.1