hackage-db-1.9.1: provide access to the Hackage database via Data.Map

LicenseBSD3
Maintainersimons@cryp.to
Stabilityprovisional
Portabilityportable
Safe HaskellNone
LanguageHaskell98

Distribution.Hackage.DB.Parsed

Description

This module provides simple access to the Hackage database by means of Map.

Synopsis

Documentation

type Hackage = Map String (Map Version GenericPackageDescription) Source

A Map representation of the Hackage database. For sake of simplicity, we use String rather than PackageName to represent the name of a package.

readHackage :: IO Hackage Source

Read the Hackage database from the location determined by hackagePath and return a Map that provides fast access to its contents.

readHackage' :: FilePath -> IO Hackage Source

Read the Hackage database from the given FilePath and return a Hackage map that provides fast access to its contents.

parseHackage :: ByteString -> Hackage Source

Parse the contents of Hackage's 00-index.tar into a Hackage map.

parseUnparsedHackage :: Hackage -> Hackage Source

Convert an Hackage map into a parsed Hackage map.