summaryrefslogtreecommitdiff
path: root/cli/js/ops/tty.ts
blob: 8899ca5b80ceffccee25f2733b0992a4926ead1e (plain)
1
2
3
4
5
6
7
8
9
10
11
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.

import { sendSync } from "./dispatch_json.ts";

export function isatty(rid: number): boolean {
  return sendSync("op_isatty", { rid });
}

export function setRaw(rid: number, mode: boolean): void {
  sendSync("op_set_raw", { rid, mode });
}