On 24/02/09 15:09, Ben Fritz wrote:
>
>
> On Feb 24, 4:08 am, Paddy<[email protected]> wrote:
>
>> So what's the best way of finding what platform you are on in vim? I
>> know I can do it using one of the scripting interfaces, but what about
>> in normal vimscript?
>
> has('win32'), has('win16'), etc.
>
> :help has()
> :help feature-list
There are so many different has() features for Dos/Windows platforms,
usually I write
if has('unix')
" this is Unix-like (Linux, or maybe OSX)
else
" we're probably on Windows (or maybe Dos)
endif
Some more exotic names are available, such as "win32unix" for Cygwin,
"macunix" for OSX, etc., but usually the blanket has('unix') is good enough.
Best regards,
Tony.
--
This is the story of the bee
Whose sex is very hard to see
You cannot tell the he from the she
But she can tell, and so can he
The little bee is never still
She has no time to take the pill
And that is why, in times like these
There are so many sons of bees.
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---