I decided to move my website from hugo to wordpress. Converting 300 articles manually was not much fun, I didn't find any tool which would be able to do . So, I write my own.
Enter hugo2wordpress
It took me an hour or two to write this utility, which will load my hugo article, convert it to wordpress article, and add it to drafts in wordpress. Then, all I need to do is press publish after I review that everything is converted correctly.
This is just initial release, not ready for use yet.
Install: npm install -g hugo2wordpress
Create .env file in your current dir:
# .env
WP_URL=https://yourwebsite.com
[email protected]
WP_PASSWORD=YOUR PASSWORD
HUGO_HOME=/Users/user/projects/web/yourwebsite.com
node index.js <article>.md
yarn install
ts-node index.ts <MY_ARTICLE>.md