W. Wesley Groleau suggested to Timothy Luoma,
| LASTFOLDER gets re-assigned on each recipe. Maybe the tedious method of
| putting it on EVERY recipe (ugh):
|
| :0
| * whatever
| {
| :0c
| * $LASTFOLDER ?? ^appnmail \/.*
BTW, that dollar sign -- which was Luke Davis's, not Wesley's -- is
unnecessary; this time it is harmless but it can bite you hard, so it's
not a good habit to get into. Anyhow,
| { LASTFOLDER = $MATCH }
|
| :0
| the normal action for this recipe
|
| }
And that won't help either, because the "normal action" will clobber the
previous value of LASTFOLDER. (Besides, if the normal action hasn't been
done yet, $LASTFOLDER won't contain the string "appnmail" yet.)
I have only one suggestion, and it's pretty ugly itself. We'll make it a
little less ugly by putting the repeated code into an includerc file.
Instead of an action of
| appnmail pertinent_folder
use this for every call to appnmail:
{ DESTINATION=pertinent_folder INCLUDERC=$HOME/.tricklastfolderrc }
where ~/.tricklastfolderrc is as follows:
LOGABSTRACT=off
:0c
| appnmail $DESTINATION
LOGABSTRACT=on
LASTFOLDER=$DESTINATION
HOST
and of course, that will work only if there were no more rcfiles named on
the command line.