Skip to content

‼️ Convert your paths from darwin to win32 and vice versa

License

Notifications You must be signed in to change notification settings

msaaddev/cross-paths

Repository files navigation

‼️ cross-paths

version license downloads

A simple path conversion package to convert your paths across different platform

separator

  • Simple: extremely simple to use
  • Darwin to Win32: Convert your darwin based operating system paths to Windows operating system
  • Win32 to Darwin: Convert your Windows paths to darwin based operating system
  • MIT Licensed: Free to use for personal and commercial projects

Installation

# install the package
npm install cross-paths

API

  • darwinToWin32()
  • win32ToDarwin()
  • path (required)

Usage

  • Convert darwin paths to win32
const { darwinToWin32 } = require('cross-paths');

const path = `/Users/saadirfan/GitHub`

const win32Path = darwinToWin32(path); // new windows path
  • Convert win32 to darwin paths
const { win32ToDarwin } = require('cross-paths');

const path = `C:\\Users\\Saad\\GitHub`;

const darwinPath = win32ToDarwin(path); // new darwin path

⚡️ Other Projects

I have curated a detailed list of all the open-source projects I have authored. Do take out a moment and take a look.

🔑 License & Conduct