LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Vim: run shell command without acknowledgement (https://www.linuxquestions.org/questions/linux-software-2/vim-run-shell-command-without-acknowledgement-412411/)

jrdioko 02-06-2006 07:58 PM

Vim: run shell command without acknowledgement
 
I've been playing around with some mapping in vim, and I'd like a few to run a command in a shell without opening a window at the bottom that requires pressing ENTER to close. In other words, I'd like to do something like ":!xterm &" without having to press return before I can go back to the file--I just want to launch an external program without confirmation.

Valdis Grinbergs 02-25-2006 08:40 PM

jrdioko,

This worked for me to map function key 6 to open a separate xterm:
:map <F6> :!xterm&<CR><CR>
The shell flashed up for a split-second, but the second carriage return quickly brought back vim.

jrdioko 02-25-2006 08:52 PM

It seems strange I hadn't tried that before, but seems to work fine (although I still wonder if there's a better way to do it). Thanks.


All times are GMT -5. The time now is 05:28 AM.