From 31f684e71b5c5b0b22e57b0e8bdc50356f8eea09 Mon Sep 17 00:00:00 2001 From: Yoshiya Hinosawa Date: Thu, 7 Mar 2019 23:07:12 +0900 Subject: Bump CI to v0.3.2 (denoland/deno_std#245) replace Deno.platform with Deno.build Original: https://github.com/denoland/deno_std/commit/c67751659c50a3c0be5952e3092de7943aa9fa54 --- fs/globrex.ts | 3 +-- fs/globrex_test.ts | 3 +-- fs/path/constants.ts | 4 ++-- fs/walk_test.ts | 13 ++----------- 4 files changed, 6 insertions(+), 17 deletions(-) (limited to 'fs') diff --git a/fs/globrex.ts b/fs/globrex.ts index 9905cbb73..7f05146bd 100644 --- a/fs/globrex.ts +++ b/fs/globrex.ts @@ -2,10 +2,9 @@ // MIT License // Copyright (c) 2018 Terkel Gjervig Nielsen -import * as deno from "deno"; import { GlobOptions } from "./glob.ts"; -const isWin = deno.platform.os === "win"; +const isWin = Deno.build.os === "win"; const SEP = isWin ? `\\\\+` : `\\/`; const SEP_ESC = isWin ? `\\\\` : `/`; const GLOBSTAR = `((?:[^/]*(?:/|$))*)`; diff --git a/fs/globrex_test.ts b/fs/globrex_test.ts index 3f645ce9b..df36dc550 100644 --- a/fs/globrex_test.ts +++ b/fs/globrex_test.ts @@ -2,12 +2,11 @@ // MIT License // Copyright (c) 2018 Terkel Gjervig Nielsen -import * as deno from "deno"; import { test } from "../testing/mod.ts"; import { assertEquals } from "../testing/asserts.ts"; import { globrex } from "./globrex.ts"; -const isWin = deno.platform.os === "win"; +const isWin = Deno.build.os === "win"; const t = { equal: assertEquals, is: assertEquals }; function match(glob, strUnix, strWin?, opts = {}) { diff --git a/fs/path/constants.ts b/fs/path/constants.ts index cfba4ebd8..d70bb8073 100644 --- a/fs/path/constants.ts +++ b/fs/path/constants.ts @@ -1,7 +1,7 @@ // Copyright the Browserify authors. MIT License. // Ported from https://github.com/browserify/path-browserify/ -const { platform } = Deno; +const { build } = Deno; // Alphabet chars. export const CHAR_UPPERCASE_A = 65; /* A */ @@ -48,5 +48,5 @@ export const CHAR_EQUAL = 61; /* = */ export const CHAR_0 = 48; /* 0 */ export const CHAR_9 = 57; /* 9 */ -export const isWindows = platform.os === "win"; +export const isWindows = build.os === "win"; export const EOL = isWindows ? "\r\n" : "\n"; diff --git a/fs/walk_test.ts b/fs/walk_test.ts index 8391f51d7..7e6384a60 100644 --- a/fs/walk_test.ts +++ b/fs/walk_test.ts @@ -1,19 +1,10 @@ -const { - cwd, - chdir, - makeTempDir, - mkdir, - open, - platform, - remove, - symlink -} = Deno; +const { cwd, chdir, makeTempDir, mkdir, open, build, remove, symlink } = Deno; import { FileInfo } from "deno"; import { walk, walkSync, WalkOptions } from "./walk.ts"; import { test, TestFunction } from "../testing/mod.ts"; import { assert, assertEquals } from "../testing/asserts.ts"; -const isWindows = platform.os === "win"; +const isWindows = build.os === "win"; export async function testWalk( setup: (string) => void | Promise, -- cgit v1.2.3