extract_media.rb | ||
finalize_export.rb | ||
README.md | ||
wp_export.xml |
Convert your Jekyll blog to Wordpress
This is a small collection of scripts to help you move your blog from Jekyll to Wordpress.
This is pretty dirty code and heavily tailored toward my own needs, so your mileage may vary. But perhaps you'll find it at least a bit helpful.
Features
This will help you import:
- Posts
- Tags
- Images
Usage
- Read the scripts and modify them as needed. Change the username, for example. ;-) There are quite a few things in there you'll want to change.
- Copy wp_export.xml to your Jekyll data folder and
run
jekyll build
. This will create an export of all your posts in_site/wp_export.xml
. Do not import this file in Wordpress yet! - Run extract_media.rb to extract all image URLs used in the export: `ruby extract_media.rb < _site/wp_export.xml
wp_export.images.xml`.
- Run finalize_export.rb to modify the image links:
ruby finalizy_export.rb < _site/wp_export.xml > wp_export.posts.xml
. - Use the Wordpress import plugin to import
wp_export.posts.xml
(do not activate theimport attachments
option). - Use the Wordpress import plugin to import
wp_export.images.xml
, this time activating the option toimport attachments
.