summaryrefslogtreecommitdiff
path: root/cli/js/lib.deno.unstable.d.ts
diff options
context:
space:
mode:
authorRubin Bhandari <roobin.bhandari@gmail.com>2020-06-11 22:56:26 +0545
committerGitHub <noreply@github.com>2020-06-11 13:11:26 -0400
commit6ccf9037a6b36c81ea0e6ac12d0e2dbd793f6114 (patch)
treeabb74317f03844454306c6d6b52b963ffe8e1d16 /cli/js/lib.deno.unstable.d.ts
parent818a8010928cb8cef0b7043bd881c8cdce9b6efc (diff)
feat: add Deno.osName() (#5714)
Diffstat (limited to 'cli/js/lib.deno.unstable.d.ts')
-rw-r--r--cli/js/lib.deno.unstable.d.ts12
1 files changed, 12 insertions, 0 deletions
diff --git a/cli/js/lib.deno.unstable.d.ts b/cli/js/lib.deno.unstable.d.ts
index dc50416fc..f425dec56 100644
--- a/cli/js/lib.deno.unstable.d.ts
+++ b/cli/js/lib.deno.unstable.d.ts
@@ -32,6 +32,18 @@ declare namespace Deno {
* Requires `allow-read` and `allow-write` permissions. */
export function linkSync(oldpath: string, newpath: string): void;
+ /**
+ * Returns the os name.
+ *
+ * ```ts
+ * console.log(Deno.osName()); // e.g. "Linux"
+ * ```
+ *
+ */
+
+ export function osName(): string;
+
+ /** Creates `newpath` as a hard link to `oldpath`.
/** **UNSTABLE**: This API needs a security review.
*
* Creates `newpath` as a hard link to `oldpath`.