Some operations to handle the REPL resource configuration file
that is stored in $HOME/.compiler-name
rc
Author: Michael Hanus
Version: April 2021
readRC
:: CCDescription -> IO [(String,String)]
Reads the rc file. |
setRCProperty
:: CCDescription -> String -> String -> IO ()
Sets a property in the rc file. |
rcValue
:: [(String,String)] -> String -> String
Look up a configuration variable in the list of variables from the rc file. |
extractRCArgs
:: [String] -> ([String],[(String,String)])
Extract from a list of command-line arguments rc properties of the from "-Dprop=val" and return the remaining arguments and the extracted properties. |
updateRCDefs
:: [(String,String)] -> [(String,String)] -> [(String,String)]
Update list of rc properties w.r.t. |
Reads the rc file. If it is not present, the standard file from the distribution will be copied. |
Sets a property in the rc file. |
Look up a configuration variable in the list of variables from the rc file. Uppercase/lowercase is ignored for the variable names and the empty string is returned for an undefined variable. |
Extract from a list of command-line arguments rc properties of the from "-Dprop=val" and return the remaining arguments and the extracted properties. |
Update list of rc properties w.r.t. a list new properties. |