bin/rlwrap-sbcl @ d4ff64dea170

Add a handy SBCL rlwrap wrapper
author Steve Losh <steve@stevelosh.com>
date Fri, 25 Mar 2016 21:35:32 +0000
parents (none)
children (none)
#!/bin/sh
BREAK_CHARS="(){}[],^%$#@\"\";''|\\"
RLWRAP=
if [ $TERM == "dumb" ]; then  # slime
  RLWRAP=
else
  RLWRAP="rlwrap --remember --history-filename=$HOME/.sbcl_history --histsize=1000000 -c -b $BREAK_CHARS -f $HOME/.sbcl_completions"
fi
if [ $# -eq 0 ]; then
  exec $RLWRAP sbcl
else # permits #!/usr/bin/env sbcl , but breaks sbcl --help, etc.
  exec sbcl --script $*
fi