Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀
Performance!

Ryan Cao ryanccn

🚀
Performance!
View GitHub Profile
@ryanccn
ryanccn / uninstall.ts
Created May 10, 2021
Better `brew uninstall`
View uninstall.ts
import {
bold,
brightRed,
gray,
green,
} from "https://deno.land/std/fmt/colors.ts";
const packageName = Deno.args[0];
const logPrefix = gray("(brew-uninstall)");
View mod.ts
import { writeAll } from 'https://deno.land/std@0.103.0/io/util.ts';
import pLimit from 'https://cdn.skypack.dev/p-limit?dts';
const exists = async (imgId: string) => {
try {
await Deno.stat(`./downloads/${imgId}.jpg`);
} catch {
return false;
}