--- base +++ base @@ -4538,8 +4538,13 @@ _muttfiledir() { - local cur folder spoolfile + local cur prev folder spoolfile cur=`_get_cword` + prev=${COMP_WORDS[COMP_CWORD-1]} + if [[ $prev == = ]]; then + cur=${COMP_WORDS[COMP_CWORD-1]}${COMP_WORDS[COMP_CWORD]} + prev=${COMP_WORDS[COMP_CWORD-2]} + fi # This is currently not working so well. Perhaps this function should # just call _filedir() for the moment. @@ -4566,6 +4571,10 @@ local cur prev cur=`_get_cword` prev=${COMP_WORDS[COMP_CWORD-1]} + if [[ $prev == = ]]; then + cur=${COMP_WORDS[COMP_CWORD-1]}${COMP_WORDS[COMP_CWORD]} + prev=${COMP_WORDS[COMP_CWORD-2]} + fi COMPREPLY=()