Copyright | (c) 1999 - 2003 Wolfgang Lux 2011 - 2014 Björn Peemöller (bjp@informatik.uni-kiel.de) 2017 Finn Teegen (fte@informatik.uni-kiel.de) |
---|---|
License | BSD-3-clause |
Maintainer | bjp@informatik.uni-kiel.de |
Stability | experimental |
Portability | portable |
Safe Haskell | Safe |
Language | Haskell2010 |
Synopsis
- lookupCurryFile :: [FilePath] -> FilePath -> IO (Maybe FilePath)
- lookupCurryModule :: [FilePath] -> [FilePath] -> ModuleIdent -> IO (Maybe FilePath)
- lookupCurryInterface :: [FilePath] -> ModuleIdent -> IO (Maybe FilePath)
- lookupFile :: [FilePath] -> [String] -> FilePath -> IO (Maybe FilePath)
- getModuleModTime :: FilePath -> IO (Maybe UTCTime)
- writeModule :: FilePath -> String -> IO ()
- readModule :: FilePath -> IO (Maybe String)
- addVersion :: String -> String -> String
- checkVersion :: String -> String -> Either String String
Retrieving curry files
lookupCurryFile :: [FilePath] -> FilePath -> IO (Maybe FilePath) Source #
Search in the given list of paths for the given FilePath
and eventually
return the file name of the found file.
- If the file name already contains a directory, then the paths to search in are ignored.
- If the file name has no extension, then a source file extension is assumed.
:: [FilePath] | list of paths to source files |
-> [FilePath] | list of paths to library files |
-> ModuleIdent | module identifier |
-> IO (Maybe FilePath) |
Search for a given curry module in the given source file and library paths. Note that the current directory is always searched first. Returns the path of the found file.
:: [FilePath] | list of paths to search in |
-> ModuleIdent | module identifier |
-> IO (Maybe FilePath) | the file path if found |
Search for an interface file in the import search path using the
interface extension icurryExt
. Note that the current directory is
always searched first.
:: [FilePath] | Directories to search in |
-> [String] | Accepted file extensions |
-> FilePath | Initial file name |
-> IO (Maybe FilePath) |
|
Search in the given directories for the file with the specified file
extensions and eventually return the FilePath
of the file.
Reading and writing modules from files
getModuleModTime :: FilePath -> IO (Maybe UTCTime) Source #
Get the modification time of a file, if existent
Write the content to a file in the given directory.