A Docker-like CLI and HTTP API for managing headless VMs

fix: reorganize imports and improve formatting in images.ts

+4 -5
+4 -5
src/subcommands/images.ts
··· 4 4 import utc from "dayjs/plugin/utc.js"; 5 5 import { Effect, pipe } from "effect"; 6 6 import type { Image } from "../db.ts"; 7 - import { type DbError, listImages } from "../images.ts"; 7 + import { DbError } from "../errors.ts"; 8 + import { listImages } from "../images.ts"; 8 9 import { humanFileSize } from "../utils.ts"; 9 10 10 11 dayjs.extend(relativeTime); ··· 12 13 13 14 const createTable = () => 14 15 Effect.succeed( 15 - new Table( 16 - ["REPOSITORY", "TAG", "IMAGE ID", "CREATED", "SIZE"], 17 - ), 16 + new Table(["REPOSITORY", "TAG", "IMAGE ID", "CREATED", "SIZE"]) 18 17 ); 19 18 20 19 const populateTable = (table: Table, images: Image[]) => ··· 47 46 Effect.all([listImages(), createTable()]), 48 47 Effect.flatMap(([images, table]) => populateTable(table, images)), 49 48 Effect.flatMap(displayTable), 50 - Effect.catchAll(handleError), 49 + Effect.catchAll(handleError) 51 50 ); 52 51 53 52 export default async function () {