Deno.lstat(path: string | URL) : Promise<FileInfo>
解析为指定路径的Deno.FileInfo。
如果path是一个符号链接,则将返回该符号链接的信息,而不是其指向的内容。
Resolves to a Deno.FileInfo for the specified path.
If path is a symlink, information for the symlink will be returned instead of what it points to.
path: string | URL
path: string | URL
Promise<FileInfo>
Promise<FileInfo>
import { assert } from "https://deno.land/std/testing/asserts.ts";
const fileInfo = await Deno.lstat("hello.txt");
assert(fileInfo.isFile);
需要提供 allow-read 权限。
Requires allow-read permission.