mirror of
https://github.com/denoland/deno.git
synced 2024-12-23 07:44:48 -05:00
e435c2be15
Co-authored-by: Ryan Dahl <ry@tinyclouds.org>
10 lines
362 B
TypeScript
10 lines
362 B
TypeScript
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
|
|
import { sendSync, sendAsync } from "../dispatch_json.ts";
|
|
|
|
export function chmodSync(path: string, mode: number): void {
|
|
sendSync("op_chmod", { path, mode });
|
|
}
|
|
|
|
export async function chmod(path: string, mode: number): Promise<void> {
|
|
await sendAsync("op_chmod", { path, mode });
|
|
}
|