Re: problems with quotes in "send-hook lines" within .muttrc
Hi all, On Mon, 19 Jun 2000, Ronny Haryanto wrote: > On 18-Jun-2000, [EMAIL PROTECTED] wrote: > > In my .muttrc, I've put a line in the way to set my editor: > > set editor="vi -c 'set wrap' -c 'set textwidth=0' -c 'set linebreak'" > > I personally separate my vimrc for general editing and for mail > editing. Hence in mutt I put: > set editor = "vi -u ~/.vimrc-mutt" > > And in ~/.vimrc-mutt I put: > > source ~/.vimrc > set textwidth=70 > set ts=8 sw=8 sts=0 > "del sig > au BufRead * normal :g/^> -- $/,/^$/-1d gg It's even easier to source ~/.vimrc-mutt: include this line in your ~/.vimrc au BufRead /tmp/mutt* source $HOME/.vimrc-mutt and change your entry in ~/.muttrc to set editor="vim +/^$/ %s" ("+/^$/" brings your cursor to the first line after the mail header-- that's only usefull, if you have "set edit_headers" in ~/.muttrc) Ciao for now, Dirk -- Dirk Ruediger, Rostock, Germany
Re: problems with quotes in "send-hook lines" within .muttrc
On 18-Jun-2000, [EMAIL PROTECTED] wrote: > In my .muttrc, I've put a line in the way to set my editor: > set editor="vi -c 'set wrap' -c 'set textwidth=0' -c 'set linebreak'" I personally separate my vimrc for general editing and for mail editing. Hence in mutt I put: set editor = "vi -u ~/.vimrc-mutt" And in ~/.vimrc-mutt I put: source ~/.vimrc set textwidth=70 set ts=8 sw=8 sts=0 "del sig au BufRead * normal :g/^> -- $/,/^$/-1d gg Cheers, Ronny
Re: problems with quotes in "send-hook lines" within .muttrc
clemensF proclaimed on mutt-users that: >> [EMAIL PROTECTED]: > >> send-hook '~t linux-bruxelles' set editor="vi +set textwidth=72" > >what about set editor="vi \"+set textwidth=72\""? Put this in your .vimrc set tw=72 -- Suresh Ramasubramanian + [EMAIL PROTECTED] Five is a sufficiently close approximation to infinity. -- Robert Firth
Re: problems with quotes in "send-hook lines" within .muttrc
> [EMAIL PROTECTED]: > send-hook '~t linux-bruxelles' set editor="vi +set textwidth=72" what about set editor="vi \"+set textwidth=72\""? clemens
Re: problems with quotes in "send-hook lines" within .muttrc
On Sun, Jun 18, 2000 at 11:36:34PM +0200, [EMAIL PROTECTED] wrote: > In my .muttrc, I've put a line in the way to set my editor: > set editor="vi -c 'set wrap' -c 'set textwidth=0' -c 'set linebreak'" > > It works fine. But in some mailing-lists, one asked me to limit the > length of my messages at 72 characters, because his mail reader didn't > wrap correctly too long lines. It's generally considered good netiquette to limit the line lengths in mailing list and Usenet postings to 72 characters. > I've tried to put in my muttrc one of these lines : > > send-hook '~t linux-bruxelles' set editor="vi +set textwidth=72" > send-hook '~t linux-bruxelles' set editor="vi '+set textwidth=72'" > send-hook '~t linux-bruxelles' set editor='vi +set textwidth=72' > send-hook '~t linux-bruxelles' set editor='vi "+set textwidth=72"' > send-hook '~t linux-bruxelles' set editor='vi "+set textwidth=72"' > > (this way of setting the option to vim avoids to use the > form -c "set textwidth=72") > > but in doing so, I always get the message '+set textwidth=72 unknown option' I don't really understand the rules, but here is one solution: send-hook '~t linux-bruxelles' 'set editor="vi \"+set textwidth=72\""' You may already know to do this, but just in case you don't: You will need to add another send-hook to reset your editor back to your preferred settings for the other mailing lists. Otherwise, once you send a message to linux-bruxelles, your editor will remain 'vi "+set textwidth=72"'. So, put a default send-hook like this somewhere before the '~t linux-bruxelles' send-hook: send-hook . 'set editor="vi -c \"set wrap textwidth=0 linebreak\""' Note that you don't need a separate -c option for each setting. Regards, Gary -- Gary Johnson | Agilent Technologies [EMAIL PROTECTED] | RF Communications Product Generation Unit | Spokane, Washington, USA
problems with quotes in "send-hook lines" within .muttrc
Hello, In my .muttrc, I've put a line in the way to set my editor: set editor="vi -c 'set wrap' -c 'set textwidth=0' -c 'set linebreak'" It works fine. But in some mailing-lists, one asked me to limit the length of my messages at 72 characters, because his mail reader didn't wrap correctly too long lines. I've tried to put in my muttrc one of these lines : send-hook '~t linux-bruxelles' set editor="vi +set textwidth=72" send-hook '~t linux-bruxelles' set editor="vi '+set textwidth=72'" send-hook '~t linux-bruxelles' set editor='vi +set textwidth=72' send-hook '~t linux-bruxelles' set editor='vi "+set textwidth=72"' send-hook '~t linux-bruxelles' set editor='vi "+set textwidth=72"' (this way of setting the option to vim avoids to use the form -c "set textwidth=72") but in doing so, I always get the message '+set textwidth=72 unknown option' so I don't understand how to do : I need a first sort of quote around the option of vi (necessary to combine +set and his argument), a second around all that comes after editor= , and then ? The solution ? Many thanks. -- #=---=# " ^^ Gauthier Vandemoortele " | (_/°°-ç[EMAIL PROTECTED] | | | \_`-" | | )/@mmm|| Chée de Wavre, 135c| | \nn \nn B-1360 Belgique| | | " FOE-Belgium : http://www.ful.ac.be/hotes/amisterre | #=---=#