diff --git a/src/commands/init.ts b/src/commands/init.ts index 648e236..57474a9 100644 --- a/src/commands/init.ts +++ b/src/commands/init.ts @@ -103,7 +103,7 @@ export function makeInitCommand({ config, pfs }: Deps) { titleKey: String(titleKey), }; - await pfs.write("./mkd.json", JSON.stringify(newConfig, null, 2) + "\n"); + await pfs.write("./mkd.json", `${JSON.stringify(newConfig, null, 2)}\n`); outro("Configuration saved to mkd.json"); }, diff --git a/src/commands/new.ts b/src/commands/new.ts index 880d8ab..fc2ac8b 100644 --- a/src/commands/new.ts +++ b/src/commands/new.ts @@ -32,7 +32,7 @@ export function makeNewCommand({ config, pfs }: Deps) { const fileName = filenamify(slug); const frontmatter = await generateFrontmatter(title, config); const filePath = path.join(config.blogDir, `${fileName}.md`); - + outro(`${title} created successfully`); await pfs.write(filePath, frontmatter); }, }); diff --git a/src/commands/unpublish.ts b/src/commands/unpublish.ts index 58df406..ae4f552 100644 --- a/src/commands/unpublish.ts +++ b/src/commands/unpublish.ts @@ -9,8 +9,6 @@ import { } from "../lib/commands"; import type { Config, Deps } from "../lib/deps"; -type Frontmatter = Record; - export function makeUnPublishCommand({ config, pfs }: Deps) { return command({ name: "unpublish", diff --git a/src/commands/update.ts b/src/commands/update.ts index 3900a3d..abdcb43 100644 --- a/src/commands/update.ts +++ b/src/commands/update.ts @@ -9,8 +9,6 @@ import { } from "../lib/commands"; import type { Config, Deps } from "../lib/deps"; -type Frontmatter = Record; - export function makeUpdateCommand({ config, pfs }: Deps) { return command({ name: "update",