The last weaks i searched for a way to use psISE in combination with vim (i found out its possible but hard for me to code without the ISE-comfort)
In the end i created a function/submenu in the ISE that:
- With a keyboard-shortcut ([AltGr]+[v]) starts vim with the current file and waits for the process to end
- When I'm finished editing in vim and saved the file its removed from the ISE
- And loaded again (bacause in v3 there is no file "refreshing")
# one-line
$psISE.CurrentPowerShellTab.AddOnsMenu.Submenus.Add("edit with Vim",{$cur=$psISE.CurrentFile; saps "C:\Program Files (x86)\vim\vim74\gvim.exe" $cur.FullPath -wait; $psise.currentpowershelltab.files.remove($cur); $psISE.currentpowershelltab.files.add($cur.fullpath) },'Ctrl+Alt+v')
You have to save it first or it will not be removed
(maybe you add the $psise.CurrentFile.Save()
-function)
(for permanent ISE-changes you have to put it into the $profile...)
*saps --> start-process alias