mutt variable expansion in shell command ?

Mathieu Carpentier mathieu.carpentier at yahoo.com
Wed Aug 28 18:36:18 UTC 2019


I've been searching in manuals and on google, but I could not find an
answer to my question.

Let's say I define the following variable in my muttrc file:
### where are my email accounts ?
set my_mail_root_dir = $HOME/Mail
set mbox_type = Maildir
### folders for my Hotmail account
set folder = $my_mail_root_dir/hotmail
set mbox = $folder/Inbox
set spoolfile = $folder/Inbox

I would like to use "folder" for mailboxes command:
mailboxes `echo -n "+ "; cd $folder; find . -maxdepth 1 -type d -name "*"
-printf "+'%f' "`

When I run mutt, I get the content of my home directory in the side panel:
$folder was not "expanded". It works if I use an environment variable set
before starting mutt.

Is it possible to use a mutt variable (e.g $folder) in a shell command ?

Thank you

Mathieu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mutt.org/pipermail/mutt-users/attachments/20190828/c68d5364/attachment.html>


More information about the Mutt-users mailing list