Something went wrong. Try again.
CLI for FastMail via JMAP
Something went wrong. Try again.
573 B · 18 lines
TypeScript
at main
12345678910111213141516171819#!/usr/bin/env bunimport { $ } from "bun";
const targets = [ { target: "bun-darwin-arm64", outfile: "dist/fastmail-darwin-arm64" }, { target: "bun-linux-arm64", outfile: "dist/fastmail-linux-arm64" }, { target: "bun-linux-x64", outfile: "dist/fastmail-linux-x64" },];
await $`rm -rf dist && mkdir -p dist`;
for (const { target, outfile } of targets) { console.log(`Building for ${target}...`); await $`bun build --compile --target=${target} --minify ./src/index.ts --outfile ${outfile}`; console.log(`Built ${outfile}`);}
console.log("Build complete!");