.emacs-autogen.sh
author Oleksandr Gavenko <gavenkoa@gmail.com>
Wed, 09 Feb 2011 01:03:42 +0200
changeset 566 5efbc78b8c41
parent 504 dc4a9f76fdbf
child 574 dfd8ec51803a
permissions -rwxr-xr-x
Fix error when fline is nil. Optimize regex for highlighting. Set quotes as punctuation chars to avoid highlighting text in matched quotes.

#!/bin/sh

if [ -z "$1" ]; then
  echo "Where config file?"
  exit 1
fi

cfg=$1

if which aspell; then
  echo >>$cfg
  echo "(setq-default ispell-program-name \"aspell\")" >>$cfg
  echo "(setq-default ispell-local-dictionary \"english\")" >>$cfg
elif which ispell; then
  echo >>$cfg
  echo "(setq-default ispell-program-name \"ispell\")" >>$cfg
  echo "(setq-default ispell-local-dictionary \"default\")" >>$cfg
fi