stabilize Deno.cwd and require --allow-read (#5068)

This commit is contained in:
Ryan Dahl 2020-05-04 14:23:06 -04:00 committed by GitHub
parent 191c59a591
commit 6c02b061ce
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 23 additions and 59 deletions

View file

@ -1024,21 +1024,6 @@ declare namespace Deno {
options: ConnectOptions | UnixConnectOptions
): Promise<Conn>;
/**
* **UNSTABLE**: Currently under evaluation to decide if explicit permission is
* required to get the value of the current working directory.
*
* Return a string representing the current working directory.
*
* If the current directory can be reached via multiple paths (due to symbolic
* links), `cwd()` may return any one of them.
*
* const currentWorkingDirectory = Deno.cwd();
*
* Throws `Deno.errors.NotFound` if directory not available.
*/
export function cwd(): string;
export interface StartTlsOptions {
/** A literal IP address or host name that can be resolved to an IP address.
* If not specified, defaults to `127.0.0.1`. */