Module CPM.Package.Helpers

This module contains some operations for processing packages, like installing package sources, cleaning packages, rendering package infos.

Summary of exported operations:

installPackageSourceTo :: Package -> PackageSource -> String -> IO ([LogEntry],Either LogEntry ())   
Installs the source of the package from the given source location into the subdirectory packageId pkg of the given directory.
cleanPackage :: LogLevel -> IO ([LogEntry],Either LogEntry ())   
Cleans auxiliary files in the local package, i.e., the package containing the current working directory.
renderPackageInfo :: Bool -> Bool -> Maybe Bool -> Package -> String   
Renders information about a package.
getLocalPackageSpec :: String -> IO ([LogEntry],Either LogEntry String)   
Tries to find a package specification in the current directory or one of its ancestors.
searchLocalPackageSpec :: String -> IO ([LogEntry],Either LogEntry (Maybe String))   
Tries to find a package specification in the current directory or one of its ancestors.

Exported operations:

installPackageSourceTo :: Package -> PackageSource -> String -> IO ([LogEntry],Either LogEntry ())   

Installs the source of the package from the given source location into the subdirectory packageId pkg of the given directory.

cleanPackage :: LogLevel -> IO ([LogEntry],Either LogEntry ())   

Cleans auxiliary files in the local package, i.e., the package containing the current working directory.

renderPackageInfo :: Bool -> Bool -> Maybe Bool -> Package -> String   

Renders information about a package.

getLocalPackageSpec :: String -> IO ([LogEntry],Either LogEntry String)   

Tries to find a package specification in the current directory or one of its ancestors.

searchLocalPackageSpec :: String -> IO ([LogEntry],Either LogEntry (Maybe String))   

Tries to find a package specification in the current directory or one of its ancestors. Returns Nothing if there is not package specifiction.