Can anyone tell me how I'd go about specifying a file to "source" in
my vimrc (hopefully works for both Unix & Windows)  dynamically

I have a common account that people sudo into from their own accounts.
I can determine their actual user ID with proctree, so I'd like to
allow them to create their own custom vimrc to load when they are in
the common account.

ssh -l foo hostname
foo#> sudo bar
bar#> vim
<Loads vim with .vimrc, which loads .vimrc_foo>

I tried to do this in my .vimrc as a test:
let g:myvar = ".vimrc_foo"
source g:myvar

I get an error
E484: Can't open file g:mysrc

Does anyone know how I can reference the file to be sourced with a
variable?

Thanks in advance!

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

Reply via email to