2019-11-01 15:46:43 +03:00
|
|
|
-- Consider copying this to your ~/.ghc/ghci.conf file:
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Pretty-printing
|
2019-11-01 16:58:14 +03:00
|
|
|
:set -ignore-package pretty-simple -package pretty-simple
|
2019-11-01 15:46:43 +03:00
|
|
|
:def! pretty \ _ -> pure ":set -interactive-print Text.Pretty.Simple.pPrint"
|
|
|
|
:def! no-pretty \ _ -> pure ":set -interactive-print System.IO.print"
|
|
|
|
:def! r \_ -> pure ":reload\n:pretty"
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Turn on some language extensions you use a lot
|
|
|
|
:seti -XFlexibleContexts -XOverloadedStrings -XTypeApplications
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Break on errors
|
|
|
|
:seti -fbreak-on-error
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Automatically show the code around breakpoints
|
|
|
|
:set stop :list
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Use a cyan lambda as the prompt
|
|
|
|
:set prompt "\ESC[1;36m\STXλ \ESC[m\STX"
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Better errors
|
|
|
|
:set -ferror-spans -freverse-errors -fprint-expanded-synonyms
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Path-local ghci history
|
|
|
|
:set -flocal-ghci-history
|
2019-10-30 23:05:49 +03:00
|
|
|
|
2019-11-01 15:46:43 +03:00
|
|
|
-- Better typed holes
|
|
|
|
:set -funclutter-valid-hole-fits -fabstract-refinement-hole-fits -frefinement-level-hole-fits=2
|