From: Simon Ruderich Date: Sat, 14 Jan 2012 14:35:18 +0000 (+0100) Subject: zsh/rc: Use ghci with rlwrap if available. X-Git-Url: https://ruderich.org/simon/gitweb/?a=commitdiff_plain;h=cff3a4b308088bca67911e89cc5d8e3d407717f1;p=config%2Fdotfiles.git zsh/rc: Use ghci with rlwrap if available. --- diff --git a/zsh/rc b/zsh/rc index 06e03f9..84b27f7 100644 --- a/zsh/rc +++ b/zsh/rc @@ -650,6 +650,15 @@ xpdf() { disown %command } +# GHCI doesn't use readline, force it if rlwrap is available. +(( $+commands[rlwrap] )) && ghci() { + command rlwrap \ + --always-readline --complete-filenames -t dumb \ + --histsize 5000 \ + --file ~/.shell/rlwrap/ghci \ + ghci "$@" 2>&1 +} + # OS SPECIFIC SETTINGS