vim-pandoc / vim-pandoc-legacy

[UNSUPPORTED/use vim-pandoc/vim-pandoc] vim bundle for pandoc users
143 stars 23 forks source link

detecting cygwin, windows, etc. #20

Closed dsanson closed 13 years ago

dsanson commented 13 years ago

Right now, we detect OS in python, and aren't checking to see if we are running under cygwin. Take a look at :h has() and :h feature-list. In particular, note

has('win16')
has('win32')
has('win64')
has('win95')
has('win32unix') (true if cygwin)
has('macunix') (true if OS X)

etc. This gives us fairly fine grained detection of what we are working with...

fmoralesc commented 13 years ago

What is the value of python's sys.platform in cygwin?

dsanson commented 13 years ago

Looks like it is 'cygwin':

http://docs.python.org/library/sys.html#sys.platform

fmoralesc commented 13 years ago

So, what advantage does the has() value give us over the current approach? What difference should we expect under cygwin?

dsanson commented 13 years ago

The current approach is fine. Also I thought there was a note in the source raising a worry about how to handle cygwin, but I see that is now gone.

This was part of my ruminations on avoiding dependence on python and ruby where possible. Sorry for the confusion. Move along. Nothing to see here :-)