Vim exec command in command line, and Vim: Warning: Input is not from a terminal -


vi.sh

vim -c "set ft=unix" -c "x" $1 

main.sh

sh vi.sh file1 sh vi.sh file2 

if exec sh vi.sh file1 or sh main.sh, there no warning.

but if exec cat main.sh | sh, give:vim: warning: input not terminal.

what difference? how can dismiss warning message when run cat main.sh | sh?

in ~/bin/r

[ $# -eq 0 ] && set -- -; vim -r "$@" 

in .vimrc:

au stdinreadpost * set buftype=nofile 

Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -