Re: Macro variable with current folder name?

2023-03-11 Thread Dennis Preiser
On Sat, Mar 11, 2023 at 01:05:13PM -0500, José María Mateos wrote: > On Sat, Mar 11, 2023 at 06:15:14PM +0100, Dennis Preiser wrote: >> >> folder-hook . 'set my_record=$record; \ >> set record=^; \ >> macro index,pager G "echo $record"; \ >> set record=$my_record' > > Thanks for your suggestion.

Re: Macro variable with current folder name?

2023-03-11 Thread José María Mateos
On Sat, Mar 11, 2023 at 07:30:13PM +0100, Dennis Preiser wrote: When I use the following macro inside the folder-hook (I don't have offlineimap) macro index,pager G "!/bin/echo $record\n"; \ Ok, found the issue. The problem is that the folder name contains '=' (as in =INBOX) and for folders

Re: Macro variable with current folder name?

2023-03-11 Thread José María Mateos
On Sat, Mar 11, 2023 at 06:15:14PM +0100, Dennis Preiser wrote: folder-hook . 'set my_record=$record; \ set record=^; \ macro index,pager G "echo $record"; \ set record=$my_record' Thanks for your suggestion. I tried this: folder-hook . 'set

Re: Macro variable with current folder name?

2023-03-11 Thread Dennis Preiser
On Sat, Mar 11, 2023 at 09:19:22AM -0500, José María Mateos wrote: > I have this macro: > > macro index,pager G "!offlineimap -o -l /tmp/offlineimap.log\n" "Retrieve new > IMAP messages" > > It works well, but I typically use only for =INBOX, so checking all the > folders (the default

Re: Macro variable with current folder name?

2023-03-11 Thread Dennis Preiser
On Sat, Mar 11, 2023 at 07:30:13PM +0100, Dennis Preiser wrote: > Just to be sure: You don't have another macro "macro index,pager G ..." > behind the folder-hook? This question is nonsense, the folder hook would overwrite it. Dennis

Macro variable with current folder name?

2023-03-11 Thread José María Mateos
Hi everybody, I have this macro: macro index,pager G "!offlineimap -o -l /tmp/offlineimap.log\n" "Retrieve new IMAP messages" It works well, but I typically use only for =INBOX, so checking all the folders (the default behaviour) is a waste. I've been trying to find if there's any way to