Re: [OT] Re: Mutt + Screen + Vim question

2000-11-04 Thread Steve Bankowitz

Kai Blin [[EMAIL PROTECTED]] wrote:

> * Conor Daly <[EMAIL PROTECTED]> [04/11/00, 12:52:53]:
>
> > What's the advantage of using screen over the  - 
> > consoles?  Can screen be used remotely or something?
>
> Yes, you can detach the session and logout / login from another
> console and retach the session... I'm using this for my IRC client,
> not for mutt, though

And more importantly I'm on a Solaris box! :-) No virtual consoles here.



Re: [OT] Re: Mutt + Screen + Vim question

2000-11-04 Thread Kai Blin

* Conor Daly <[EMAIL PROTECTED]> [04/11/00, 12:52:53]:

> > solution I'm suggesting has absolutely nothing to do with mutt and
> > everything to do with screen.  Mutt can't do what you think you want
> > it to do.  You need to tell screen you want a new screen, and you want
> > to run mutt in that new screen.
> > 
> 
> What's the advantage of using screen over the  - 
> consoles?  Can screen be used remotely or something?

Yes, you can detach the session and logout / login from another console and
retach the session... I'm using this for my IRC client, not for mutt, though
:)

Kai

-- 
Kai Blin Webmasterof  http://www.uni-tuebingen.de/uni/thm/molgen/
Univ. of Tuebingen  Inst. of   Human   Genetics  fon +49-7071-2974890
Wilhelmstrasse 27   Dept. of Molecular Genetics  fax +49-7071-295233
D-72074 Tuebingen   Do molecular biologists wear designer genes?



[OT] Re: Mutt + Screen + Vim question

2000-11-04 Thread Conor Daly

On Fri, Nov 03, 2000 at 05:25:02PM -0800 or thereabouts, Brian D. Winters wrote:
> 
> solution I'm suggesting has absolutely nothing to do with mutt and
> everything to do with screen.  Mutt can't do what you think you want
> it to do.  You need to tell screen you want a new screen, and you want
> to run mutt in that new screen.
> 

What's the advantage of using screen over the  - 
consoles?  Can screen be used remotely or something?

-- 
Conor Daly 
Met Eireann, Glasnevin Hill, Dublin 9, Ireland
Ph +353 1 8064217 Fax +353 1 8064275




Re: Mutt + Screen + Vim question

2000-11-03 Thread Brian D. Winters

On Fri, Nov 03, 2000 at 07:07:28PM -0500, Steve Bankowitz wrote:
> Brian D. Winters [[EMAIL PROTECTED]] wrote:
> > On Fri, Nov 03, 2000 at 03:19:30PM -0500, Steve Bankowitz wrote:
> > > (pretty standard stuff.)  But every once and a while I would like to
> > > jump back to Mutt to check a message.  Since I'm running screen I
> > > thought, ``Oh, I'll just spawn vim off in another screen and then jump
> > > back to mutt if need be.''
> > 
> > Why not leave your editor stuff alone, and spawn another mutt in
> > another screen?
> 
> How would I do that?  Would I write a macro for `m`?

And how would you invoke that 'm' macro from inside vim??? :)  The
solution I'm suggesting has absolutely nothing to do with mutt and
everything to do with screen.  Mutt can't do what you think you want
it to do.  You need to tell screen you want a new screen, and you want
to run mutt in that new screen.

The only way to interrupt composing a message and use mutt to browse
e-mail is to postpone the current message (exit your editor, then
invoke , probably with the 'P' key), browse away,
and then resume the postponed message (probably with 'R').  You can't
"jump back to mutt" from your editor, because mutt is waiting for vim
to terminate, and if I read your message correctly, you want to browse
messages in mutt without exiting vim.  That just won't work.

Brian



Re: Mutt + Screen + Vim question

2000-11-03 Thread Steve Bankowitz

Brian D. Winters [[EMAIL PROTECTED]] wrote:
> On Fri, Nov 03, 2000 at 03:19:30PM -0500, Steve Bankowitz wrote:
> > (pretty standard stuff.)  But every once and a while I would like to
> > jump back to Mutt to check a message.  Since I'm running screen I
> > thought, ``Oh, I'll just spawn vim off in another screen and then jump
> > back to mutt if need be.''
> 
> Why not leave your editor stuff alone, and spawn another mutt in
> another screen?

How would I do that?  Would I write a macro for `m`?

  macro index m |screen mutt < %s

Or something along those lines?



Re: Mutt + Screen + Vim question

2000-11-03 Thread Brian D. Winters

On Fri, Nov 03, 2000 at 03:19:30PM -0500, Steve Bankowitz wrote:
> (pretty standard stuff.)  But every once and a while I would like to
> jump back to Mutt to check a message.  Since I'm running screen I
> thought, ``Oh, I'll just spawn vim off in another screen and then jump
> back to mutt if need be.''

Why not leave your editor stuff alone, and spawn another mutt in
another screen?

Brian



Mutt + Screen + Vim question

2000-11-03 Thread Steve Bankowitz

I currently use something along the lines (in my $HOME/.muttrc)

  set editor="vim '+/^$'"

(pretty standard stuff.)  But every once and a while I would like to
jump back to Mutt to check a message.  Since I'm running screen I
thought, ``Oh, I'll just spawn vim off in another screen and then jump
back to mutt if need be.''

Well if I do just that:

  set editor="screen vim -f '+/^$'"

Screen spawns off a vim session just fine, but the contents of the file
is empty.  I used the `-f` thinking that vim was detaching from the
shell, but know difference is noticed.

So my next try was to write a quick wrapper around screen and vim and
pass it argv1.

  % cat hack 
  #!/bin/sh
  /usr/apps/bin/screen /usr/apps/bin/vim -- $1

And in my .muttrc file.

  set editor="/home/sbank/hack"

Still no go.  Screen spawns with vim, but no e-mail message to edit.

Does anyone have any suggestions?  (I looked in the mail archives, but
all I came up with is someone saying you should try the `-x` option to
vim.  Which is clearly wrong if you just do a quick man on vim.)

Thanks,
Steve