Aeons ago I started with Movable Type, then switched to Wordpress. Now I'd like to take away a ton of dependencies and just let it run by a static site generator.
At the moment, Hugo in combination with Netlify seems like a compelling solution to simplify my life.
git clone https://github.com/thomasf/exitwp.git ~/Dev/exitwp
in your terminal.
This piece of fine software converts a WordPress export to a bunch of Markdown files and also grabs (most of) the images.exitwp
would like to have it: cp ~/Downloads/*.xml ~/Dev/exitwp/wordpress-xml
exitwp
: cd ~/Dev/exitwp/ && python2.7 exitwp.py
(If you set download_images: True
in config.yaml
you should also get (most of) the images).~/Dev/exitwp/build/jekyll/habi.gna.ch
.cd ~/Dev && hugo new site blog --force
.
This only has to be done the first time...cd blog
git submodule add https://github.com/budparr/gohugo-theme-ananke.git themes/ananke
echo 'theme = "ananke"' >> config.toml
config.toml
to taste.hugo-export.zip
file from above.blog
directory: mkdir -p ~/Dev/blog/content/posts && cp ~/Dev/exitwp/build/jekyll/habi.gna.ch/_posts/* ~/Dev/blog/content/posts/
exitwp
directory to the blog
directory: mkdir -p ~/Dev/blog/static/images && cp ~/Dev/exitwp/build/jekyll/habi.gna.ch/images/*/*.* ~/Dev/blog/static/images/
. We move the images from their subfolder to a single new folder.cd ~/Dev/blog && hugo server
. All images are still served from their original URLs.blog CNAME very-fancy-strings-with-numbers.netlify.com