Re: typing cmds 2x for cygwin shell

2007-02-15 Thread drchip
Quoting Kev <[EMAIL PROTECTED]>:

> I use the cygwin shell from within Vim by using the following in my _vimrc
> : set shell=c:\cygwin\cygwin.bat
> If I use :r!date to insert the current date, the shell will open and I
> have to type the command "date" again. Then after typing "exit" the
> shell exits and the date is placed in the buffer. Any suggestions on how
> to avoid typing the command a second time?

Please try the following settings in your .vimrc:

"  set shell : name of shell to use for ! and :! commands
"  set shq   : shellquote   -- how to qquote characters about the cmd passed to
shell
"  set sxq   : shellxquote  -- includes redirection (shellquote excludes that)
"  set ssl   : shellslash   -- when set, forward slash used to expand file names
"  set shcf  : shellcmdflag -- flag passed to shell to execute ! and :! commands
"  set sp: shellpipe-- string used to put output of :make into errorfile
"  set srr   : shellredir   -- string used to put output of filter cmd into
temporary file
  set shell=bash
  set shq=
  set sxq=\"
  set ssl
  set shcf=-c
  set sp=>&

HTH,
Chip Campbell




RE: typing cmds 2x for cygwin shell

2007-02-15 Thread Dr. Uwe Schneider
@Kevin

vim passes the date command somehow to the shell invoked. If you set the shell 
to your script, which is calling the real shell, the information about to 
invoke the date command gets lost.

Regards, Doc

>I use the cygwin shell from within Vim by using the following in my _vimrc
>: set shell=c:\cygwin\cygwin.bat
>If I use :r!date to insert the current date, the shell will open and I 
>have to type the command "date" again. Then after typing "exit" the 
>shell exits and the date is placed in the buffer. Any suggestions on how 
>to avoid typing the command a second time?
>Thanks, Kevin