CLI tool for batch updating jekyll markdown content files to markdown files useable by Gatsby (changing the date and slug)
Written in Rust, can be run with Cargo
Install the command
bash
cargo install jekyll-to-gatsby
Run the command
cd my-folder-with-posts
jekyll-to-gatsby
The new files should appear in the output
folder
Use jekyll-to-gatsby --help
Given a directory of Jekyll markdown post files, with a structure like this:
- some-folder
- 2012-02-23-a-post.md
- 2020-06-12-another-post.md
output
folder (configurable), extracting the date from the file name.date
field in the frontmatter header of each post so Gatsby can find the date.{{ site.url }}{{ site.baseurl }}
syntax in URLs from Jekyll to remove it. You can move your previous Jekyll assets
folder to the static
folder in Gatsby and paths should work.New structure (based on the structure used in the Gatsby Starter Blog:
- some-folder
- a-post
- index.md
- another-post
- index.md