Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

powershell as gvim(vim) :shell

i'm on a Windows 7 machine and i've installed Gvim(win32 version not MinGW or something alike), i've written in my _vimrc

set shell=powershell.exe

Now when i type :shell command it must open a new buffer with powershell in it but instead it opens powershell in a new window.

Question : Is there a way to set Gvim ( configuration or plugin ) to open PowerShell in a buffer (like bash)?

like image 991
ilcredo Avatar asked Dec 05 '10 12:12

ilcredo


People also ask

Can I use vim in PowerShell?

Now, the vim command works in terminal and PowerShell windows.

Does PowerShell have a text editor?

Using Nano as a PowerShell Text Editor. If you are new to terminal-based text editors or only need to make a quick edit to a file, Nano is ideal for you. Nano is lightweight, intuitive, and more suited for light text editing tasks compared to the other more advanced editors in this tutorial.

How do I open text editor in PowerShell?

Method 1: Using Notepad The easiest way to edit a text file in PowerShell on your Windows machine is to run the command notepad.exe my_text_file. txt , or simply notepad my_text_file. txt , in your PowerShell terminal to open the text file with the visual editor Notepad.

Does vim work on Windows?

Vim editor was specifically designed for Unix-based operating systems, but later it was also ported to the Windows platform.


1 Answers

  1. Reread documentation for :shell and design-not. Quote from design-not:

    Vim is not a shell or an Operating System. You will not be able to run a shell inside Vim or use it to control a debugger. This should work the other way around: Use Vim as a component from a shell or in an IDE. A satirical way to say this: "Unlike Emacs, Vim does not attempt to include everything but the kitchen sink, but some people say that you can clean one with it. ;-)"

  2. Of course, somebody does not like this. There are some projects that make it possible to run shell inside vim, most known is Conque which now has windows support. Note that it does not work with unicode.

like image 180
ZyX Avatar answered Oct 11 '22 18:10

ZyX