From 16ef2a726646ba444e4c876078bd77d81c095298 Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Tue, 16 May 2000 00:51:04 +0000 Subject: 11396: Completion/User/_look: display a message when an argument is empty. --- ChangeLog | 3 +++ Completion/User/_look | 9 ++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1945cfd22..fbe2909b0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2000-05-16 Tanaka Akira + * 11396: Completion/User/_look: display a message when + an argument is empty. + * 11394: Completion/User/_cvs: rewrite filename completion functions. diff --git a/Completion/User/_look b/Completion/User/_look index ea53867ee..e6c77a45e 100644 --- a/Completion/User/_look +++ b/Completion/User/_look @@ -8,11 +8,14 @@ _arguments -C -s \ '-f[case insensitive]' \ '-d[dictionary order]' \ ':string:->string' \ - ':dictionary file:_files -f' && return 0 + ':dictionary file:_files' && return 0 case "$state" in string) - [[ -n "$PREFIX" ]] && - _wanted values expl 'word prefix' compadd - $(_call values $words[1] $PREFIX) + if [[ -n "$PREFIX" ]]; then + _wanted values expl 'word prefix' compadd - $(_call values $words[1] $PREFIX) + else + _message 'word prefix' + fi ;; esac -- cgit 1.4.1