import { promises } from "fs" import { compile } from "./compile" const { readFile } = promises if (process.argv.length !== 3) { console.error("usage: gbuoy ") process.exit(1) } const fileName = process.argv[2] readFile(fileName, { encoding: "utf-8" }).then(source => { const output = compile(source) console.log(output) })