biegunka-archive-0.2.0.0: Tar/Zip archives support as Source.

Safe HaskellNone

Control.Biegunka.Source.Tar

Contents

Description

Biegunka.Source.Tar - functions to work with [.tar, .tar.gz, .tar.bz2] archives as sources

Synopsis

Source layer

tar :: String -> FilePath -> Script Actions () -> Script Sources ()Source

Download and extract tar archive (possibly with compression) from the given url to specified path. Also executes attached script

 tar "https://example.com/archive.tar.gz" "tar/archive" $ do
   register "some/not/so/long/path"
   link "important.file" ".config"
  • download and extract archive from https://example.com/archive.tar.gz to ${HOME}/tar/archive
  • link ${HOME}/tar/archive to ${HOME}/some/not/so/long/path
  • link ${HOME}/tar/archive/important.file to ${HOME}/.config

tar_ :: String -> FilePath -> Script Sources ()Source

Download and extract tar archive (possibly with compression) from the given url to specified path.

 tar_ "https://example.com/archive.tar.gz" "tar/archive"
  • download and extract archive from https://example.com/archive.tar.gz to ${HOME}/tar/archive