mirror of
https://github.com/denoland/deno.git
synced 2025-09-29 21:54:48 +00:00
Cleanup comments and internal variables (#4205)
This commit is contained in:
parent
809019dc6e
commit
6cd46fa3ef
25 changed files with 681 additions and 572 deletions
|
@ -26,19 +26,24 @@ function mkdirArgs(
|
|||
}
|
||||
|
||||
export interface MkdirOption {
|
||||
/** Defaults to `false`. If set to `true`, means that any intermediate
|
||||
* directories will also be created (as with the shell command `mkdir -p`).
|
||||
* Intermediate directories are created with the same permissions.
|
||||
* When recursive is set to `true`, succeeds silently (without changing any
|
||||
* permissions) if a directory already exists at the path. */
|
||||
recursive?: boolean;
|
||||
/** Permissions to use when creating the directory (defaults to `0o777`,
|
||||
* before the process's umask).
|
||||
* Does nothing/raises on Windows. */
|
||||
mode?: number;
|
||||
}
|
||||
|
||||
/** Creates a new directory with the specified path synchronously.
|
||||
* If `recursive` is set to true, nested directories will be created (also known
|
||||
* as "mkdir -p").
|
||||
* `mode` sets permission bits (before umask) on UNIX and does nothing on
|
||||
* Windows.
|
||||
/** Synchronously creates a new directory with the specified path.
|
||||
*
|
||||
* Deno.mkdirSync("new_dir");
|
||||
* Deno.mkdirSync("nested/directories", { recursive: true });
|
||||
*/
|
||||
*
|
||||
* Requires `allow-write` permission. */
|
||||
export function mkdirSync(
|
||||
path: string,
|
||||
optionsOrRecursive?: MkdirOption | boolean,
|
||||
|
@ -48,14 +53,11 @@ export function mkdirSync(
|
|||
}
|
||||
|
||||
/** Creates a new directory with the specified path.
|
||||
* If `recursive` is set to true, nested directories will be created (also known
|
||||
* as "mkdir -p").
|
||||
* `mode` sets permission bits (before umask) on UNIX and does nothing on
|
||||
* Windows.
|
||||
*
|
||||
* await Deno.mkdir("new_dir");
|
||||
* await Deno.mkdir("nested/directories", { recursive: true });
|
||||
*/
|
||||
*
|
||||
* Requires `allow-write` permission. */
|
||||
export async function mkdir(
|
||||
path: string,
|
||||
optionsOrRecursive?: MkdirOption | boolean,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue