diff options
| author | Mirek Kratochvil <exa.exa@gmail.com> | 2023-01-14 23:30:44 +0100 |
|---|---|---|
| committer | Mirek Kratochvil <exa.exa@gmail.com> | 2023-01-14 23:30:44 +0100 |
| commit | 8a7d54a74e3229d7936426b4d100f97420a6e282 (patch) | |
| tree | dbf9fd2771615ebfdb76ab7c55129c71efeb7c92 /app/Main.hs | |
| parent | d9f5bcc0f957fbc148e3d58102d87e95859410e3 (diff) | |
| download | prlg-8a7d54a74e3229d7936426b4d100f97420a6e282.tar.gz prlg-8a7d54a74e3229d7936426b4d100f97420a6e282.tar.bz2 | |
histories
Diffstat (limited to 'app/Main.hs')
| -rw-r--r-- | app/Main.hs | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/app/Main.hs b/app/Main.hs index 5f103f0..1a1bfff 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -1,7 +1,12 @@ module Main where import Frontend (interpreter) -import System.Console.Haskeline (defaultSettings, runInputT) +import System.Console.Haskeline (Settings(..), defaultSettings, runInputT) +import System.Environment (lookupEnv) main :: IO () -main = runInputT defaultSettings interpreter +main = do + hf <- lookupEnv "HOME" + runInputT + defaultSettings {historyFile = fmap (++ "/.prlg_history") hf} + interpreter |
