2018-12-18 21:29:39 -05:00
|
|
|
// Copyright the Browserify authors. MIT License.
|
2020-03-30 11:36:55 -04:00
|
|
|
// Ported mostly from https://github.com/browserify/path-browserify/
|
2021-01-02 10:17:01 -05:00
|
|
|
// This module is browser compatible.
|
2018-12-18 21:29:39 -05:00
|
|
|
|
2020-11-13 18:21:11 -05:00
|
|
|
import { isWindows } from "../_util/os.ts";
|
2019-05-13 12:32:33 -04:00
|
|
|
import * as _win32 from "./win32.ts";
|
|
|
|
import * as _posix from "./posix.ts";
|
|
|
|
|
|
|
|
const path = isWindows ? _win32 : _posix;
|
|
|
|
|
|
|
|
export const win32 = _win32;
|
|
|
|
export const posix = _posix;
|
2020-03-30 11:36:55 -04:00
|
|
|
export const {
|
|
|
|
basename,
|
2020-04-29 16:20:55 -04:00
|
|
|
delimiter,
|
|
|
|
dirname,
|
2020-03-30 11:36:55 -04:00
|
|
|
extname,
|
|
|
|
format,
|
2020-04-29 16:20:55 -04:00
|
|
|
fromFileUrl,
|
|
|
|
isAbsolute,
|
|
|
|
join,
|
|
|
|
normalize,
|
2020-03-30 11:36:55 -04:00
|
|
|
parse,
|
2020-04-29 16:20:55 -04:00
|
|
|
relative,
|
|
|
|
resolve,
|
2020-03-30 11:36:55 -04:00
|
|
|
sep,
|
2020-10-19 08:36:53 -04:00
|
|
|
toFileUrl,
|
2020-04-29 16:20:55 -04:00
|
|
|
toNamespacedPath,
|
2020-03-30 11:36:55 -04:00
|
|
|
} = path;
|
2019-10-16 14:39:33 -04:00
|
|
|
|
2020-05-09 08:34:47 -04:00
|
|
|
export * from "./common.ts";
|
|
|
|
export { SEP, SEP_PATTERN } from "./separator.ts";
|
2020-05-31 13:48:32 -04:00
|
|
|
export * from "./_interface.ts";
|
2019-10-16 14:39:33 -04:00
|
|
|
export * from "./glob.ts";
|