Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: zsh Newbie wants to complete mutt email addresses or aliases



I wrote this :

    # added by asyd (20020304)
    if [ -r ~/.muttrc ]; then

       # use cache
       if ( [[ ${+_list_alias} -eq 0 ]] || _cache_invalid mutt_alias ) &&
          ! _retrieve_cache mutt_alias; then

          _list_alias=(${(o)${${(M)${(f)"$(< ~/.muttrc)"}##alias*}/alias /}%% *})

          _store_cache mutt_alias _list_alias
       fi

       _wanted alias expl 'alias name' compadd -q -S, $_list_alias
    fi


-- 
Bruno Bonfils
Admin Sys GNU/Linux

 http://www.debian-fr.org/



Messages sorted by: Reverse Date, Date, Thread, Author