summaryrefslogtreecommitdiff
path: root/contrib/lisp
diff options
context:
space:
mode:
authorDavid Paleino <d.paleino@gmail.com>2009-10-10 17:15:58 +0200
committerDavid Paleino <d.paleino@gmail.com>2009-10-10 17:15:58 +0200
commite5a9b6220e93ca656fd9774c6aefa78241edca6f (patch)
tree4a65aa19b18fe2e8dcec24a1c97ce9746a6f91ff /contrib/lisp
parent96d00c3d7f1912d4f3f76f8ea21ef68d179b8b30 (diff)
downloadbash-completion-upstream/1.1.tar.gz
Imported Upstream version 1.1upstream/1.1
Diffstat (limited to 'contrib/lisp')
-rw-r--r--contrib/lisp25
1 files changed, 15 insertions, 10 deletions
diff --git a/contrib/lisp b/contrib/lisp
index be8e1f92..cf9e2f8b 100644
--- a/contrib/lisp
+++ b/contrib/lisp
@@ -1,9 +1,7 @@
-# -*- mode: shell-script; sh-basic-offset: 8; indent-tabs-mode: t -*-
-# ex: ts=8 sw=8 noet filetype=sh
-#
# bash programmable completion for various Common Lisp implementations by
# Nikodemus Siivola <nikodemus@random-state.net>
+have lisp &&
_lisp()
{
local cur
@@ -13,14 +11,21 @@ _lisp()
# completing an option (may or may not be separated by a space)
if [[ "$cur" == -* ]]; then
- COMPREPLY=( $( compgen -W '-core -lib -batch -quit -edit -eval -init \
- -dynamic-space-size -hinit -noinit -nositeinit -load \
- -slave ' \
- -- $cur ) )
+ COMPREPLY=( $( compgen -W '-core -lib -batch -quit -edit -eval -init \
+ -dynamic-space-size -hinit -noinit -nositeinit -load -slave ' \
+ -- "$cur" ) )
else
- _filedir
+ _filedir
fi
return 0
-}
-complete -F _lisp -o default lisp
+} &&
+complete -F _lisp $default lisp
+
+# Local variables:
+# mode: shell-script
+# sh-basic-offset: 4
+# sh-indent-comment: t
+# indent-tabs-mode: nil
+# End:
+# ex: ts=4 sw=4 et filetype=sh