unwin

Transform windows absolute paths into UNIX paths.

  • unwin

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
unwin
001.0.28 years ago9 years agoMinified + gzip package size for unwin in KB

Readme

unwin
Transform windows absolute paths into UNIX paths.
NPM

Install

npm install --save unwin

Examples

On Windows:
> require('os').platform()
'win32'
> unwin = require('unwin');
[Function: unwin]
> unwin('c:\\')
'/'
> unwin('\\top\\test\\file1.test.js')
'/top/test/file1.test.js'

On Linux:
> unwin = require('unwin');
[Function: unwin]
> unwin('c:\\')
'c:\\'
> unwin('\\top\\test\\file1.test.js')
'\\top\\test\\file1.test.js'