Re: save-message to ? and then sync the folder
- To: mutt-users@xxxxxxxx
- Subject: Re: save-message to ? and then sync the folder
- From: Kyle Wheeler <kyle-mutt@xxxxxxxxxxxxxx>
- Date: Mon, 1 Dec 2008 09:17:05 -0600
- Comment: DomainKeys? See http://domainkeys.sourceforge.net/
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed; d=memoryhole.net; h=date :from:to:subject:message-id:references:mime-version:content-type :in-reply-to; s=default; bh=w9w3Kg/ih6JjuCoO7c2NkrW3B/4=; b=ENqz kc+qUz1wtDGSCEcUxQsZ0P3LWZ3Rg9As8UWlmzANVVa8QHGZM9QBrvQJ5av/OcdU CfLXUqlEhzoQjR4sA8SXbjr7j6gKpk8x8Rjv/WZMibBzIMvgvHRsAe9Y2X0gP8Z0 TVzekud1BosReYHwa/bySjnE5V5WmKQC0kwKsHs=
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=memoryhole.net; b=d52USPWWdT4LG32AphL3B4xJes+8GuJVsgG+nb65rix2O06U+rBfBpZOoESlTiu9m56xv9C/ddYCt1UtfZlyqYiBtMzf6RYXExxGIl+mM9jqWNszIF3FYJ7Ru7jX5cJ9onj6I1ow6dTjGLpokq4G1rOF0umOqwkeNhyyz1CE1k4=; h=Received:Received:Date:From:To:Subject:Message-ID:Mail-Followup-To:References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To:OpenPGP:User-Agent;
- In-reply-to: <20081127132013.GA17151@dracona>
- List-post: <mailto:mutt-users@mutt.org>
- List-unsubscribe: send mail to majordomo@mutt.org, body only "unsubscribe mutt-users"
- Mail-followup-to: mutt-users@xxxxxxxx
- Openpgp: id=CA8E235E; url=http://www.memoryhole.net/~kyle/kyle-pgp.asc; preference=signencrypt
- References: <20081127132013.GA17151@dracona>
- Sender: owner-mutt-users@xxxxxxxx
- User-agent: Mutt/1.5.18 (2008-11-16)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Thursday, November 27 at 02:20 PM, quoth trance202@xxxxxx:
>how can I sync the mailbox after save a message to any folder like
>this:
>
>macro s "<save-message>?"
>
>the above works great, but after this save mutt should sync
>automatically. Like this:
>
>macro s "<save-message>?<sync-mailbox>"
Well, the trick here is that you're giving mutt a bunch of things to
do all at once, as others on this list have suggested. HOWEVER, I
think this can be done if you're especially clever.
The '<save-message>?' part of the macro puts you into the browser. To
then get mutt to do something as you *exit* the browser (i.e. after
you've selected an entry), you'd need to tuck your desired behavior
into the methods of exiting from the browser. For example:
macro index s "<enter-command> macro browser \\<return\\>
'<select-entry><sync-mailbox>'<enter><save-message>?"
It would be even cooler if you could have the secondary macro clean up
after itself:
macro index s "<enter-command> macro browser \\<return\\>
'<enter-command>bind browser
return<enter><select-entry><sync-mailbox>'<enter><save-message>?"
... but there seems to be some problem with the handling of <enter> in
the rebinding part that I can't quite figure out.
~Kyle
- --
Look, I can surely say by now that I've got the antibodies to
communism inside me. But when I think of consumer society, with all
its tragedies, I wonder which of the two systems is better.
-- Pope John Paul II, 1979
-----BEGIN PGP SIGNATURE-----
Comment: Thank you for using encryption!
iEYEARECAAYFAkkz//EACgkQBkIOoMqOI14IBACfcx9aKGaIIgXGXKFLVxJ/uYCu
478AnRJNnUPwqMj4H8XIKyUjNIkN3ceP
=ltLX
-----END PGP SIGNATURE-----