Re: Accessing Environmnetal Variable from a vim script
- R. shankar wrote:
> How do I access an environmental variable from a vim script ?Almost as you did. There are minor syntax differences (see ":help
> Lets us assume that PLATFORM is an environment variable which can hold two values sun4os5 or linux.
> I want to have the script as given below -
> if $PLATFORM = sun4os5
> let cmd = .....
> let cmd = .......
> end if
> How can I do this ?
eval"). So the following will work as a starting point:
if $PLATFORM == "sun4os5"
elseif $PLATFORM == "linux"
echoerr "unknown platform <" . $PLATFORM . ">"