kingcwt
generate.cjs file will help to create a new post with params title and dir, the dir default is drafts.
yarn run new --title='title-test' --dir="posts"The command will generate a markdown file under src/content/posts directory, and the markdown file content will look like this:
---
title: title-test
date: 2024-04-18T02:50:36.418Z
abbrlink: 21cdefe2
---