import * as mod from "https://deno.land/std@0.219.1/fs/mod.ts";
Helpers for working with the filesystem.
Variables
v CRLF | End-of-line character for Windows platforms. |
v EOL | End-of-line character evaluated for the current platform. |
v LF | End-of-line character for POSIX platforms such as macOS and Linux. |
Functions
f copy | Copy a file or directory. The directory can have contents. Like |
Copy a file or directory. The directory can have contents. Like | |
Detect the EOL character for string input. returns null if no newline. | |
Ensures that a directory is empty.
Deletes directory contents if the directory is not empty.
If the directory does not exist, it is created.
The directory itself is not deleted.
Requires the | |
Ensures that a directory is empty.
Deletes directory contents if the directory is not empty.
If the directory does not exist, it is created.
The directory itself is not deleted.
Requires the | |
Ensures that the directory exists.
If the directory structure does not exist, it is created. Like mkdir -p.
Requires the | |
Ensures that the directory exists.
If the directory structure does not exist, it is created. Like mkdir -p.
Requires the | |
Ensures that the file exists.
If the file that is requested to be created is in directories that do not
exist.
these directories are created. If the file already exists,
it is NOTMODIFIED.
Requires the | |
Ensures that the file exists.
If the file that is requested to be created is in directories that do not
exist,
these directories are created. If the file already exists,
it is NOT MODIFIED.
Requires the | |
Ensures that the hard link exists. If the directory structure does not exist, it is created. | |
Ensures that the hard link exists. If the directory structure does not exist, it is created. | |
Ensures that the link exists, and points to a valid file.
If the directory structure does not exist, it is created.
If the link already exists, it is not modified but error is thrown if it is not point to the given target.
Requires the | |
Ensures that the link exists, and points to a valid file.
If the directory structure does not exist, it is created.
If the link already exists, it is not modified but error is thrown if it is not point to the given target.
Requires the | |
Test whether or not the given path exists by checking with the file system. Please consider to check if the path is readable and either a file or a directory by providing additional | |
Test whether or not the given path exists by checking with the file system. Please consider to check if the path is readable and either a file or a directory by providing additional | |
Expand the glob string from the specified | |
Synchronous version of | |
Format the file to the targeted EOL. | |
f move | Moves a file or directory. |
Moves a file or directory synchronously. | |
f walk | Walks the file tree rooted at root, yielding each file or directory in the tree filtered according to the given options. |
Same as |
Interfaces
Options for | |
Options for | |
Options for | |
Walk entry for | |