Alexei Alexandrov wrote:
> Hi,
> 
> I often use something like "gvim -q build.log" to browse through the 
> build log compilation errors.
> 
> I also use something like "gvim --remote-tab-silent PATH" quite a bit to 
> open files in the already running instance of gvim.
> 
> Ideally, I'd like to combine these 2 things and be able to load existing 
>   build log into running Vim instance.
> 
> But I couldn't find a command line option which does that - all --remote 
> commands require file to open argument, but I don't need to open the 
> build.log file - I need to make it the errorfile. There is --remote-send 
> command line option but it doesn't raise Vim window so it's not 
> convenient either...
> 
> Is it possible to get what I want?

With a little jiggerypokery it should be! Perhaps something like

gvim --remote-send "<C-\><C-N>:cfile build.log<CR>:call foreground()<CR>"

You'd obviously want to wrap that in a shell script or alias...

And there are other possibilities if that doesn't work... If you're on
Windows, running remote_foreground() in the client might be better than
running foreground() in the server, for instance; then you'd have to run
a remote_send in the client, too, via a :call not using the
--remote-send argument.

Let us know how you go!

Ben.



--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui