hackage-security-0.5.2.2: Hackage security library

Safe HaskellNone
LanguageHaskell2010

Hackage.Security.Client.Repository.Local

Description

Local repository

Synopsis

Documentation

type LocalRepo = Path Absolute #

Location of the repository

Note that we regard the local repository as immutable; we cache files just like we do for remote repositories.

withRepository #

Arguments

:: LocalRepo

Location of local repository

-> Cache

Location of local cache

-> RepoLayout

Repository layout

-> IndexLayout

Index layout

-> (LogMessage -> IO ())

Logger

-> (Repository LocalFile -> IO a)

Callback

-> IO a 

Initialize the repository (and cleanup resources afterwards)

Like a remote repository, a local repository takes a RepoLayout as argument; but where the remote repository interprets this RepoLayout relative to a URL, the local repository interprets it relative to a local directory.

It uses the same cache as the remote repository.