S9Y Database

Install additional gems

To use this importer, you need to install these additional gems: `gem install unidecode sequel mysql2 htmlentities reverse_markdown`

To import your posts from a self-hosted S9Y database, run:

$ ruby -r rubygems -e 'require "jekyll-import";
      "dbname"         => "s9y_blog",
      "user"           => "root",
      "password"       => "",
      "host"           => "localhost",
      "table_prefix"   => "serendipity_",
      "clean_entities" => false,
      "comments"       => true,
      "categories"     => true,
      "tags"           => true,
      "extension"      => "html",
      "drafts "        => true,
      "markdown"       => false,
      "permalinks"     => false
This only imports post & page data & content

This importer only converts your posts and creates YAML front-matter. It does not import any layouts, styling, or external files (images, CSS, etc.).

Migration Options

This importer now supports two options to help migrate your blog to a new hosting provider.

  • relative

    Set this to your URL prefix to convert all the absolute URLs in your posts to relative. For example, when set to myhost.com/blog, URLs like http://myhost.com/blog/lifestyle/7-lucky-post.html will be converted to /lifestyle/7-lucky-post.html. Note that you should not include the trailing / slash, and that https: is not yet supported.

  • linebreak

    If you used a formatting extension, this option might be useful. Use one of the following values to try and replicate your post line breaks as closely as possible:

    • wp (the default)

      Replicate the Wordpress line break behavior, the default for S9Y.

    • nokogiri

      Uses the nokogiri gem to interpret entries as XHTML formatted. If you write HTML entries, this preserves the HTML line breaks.

    • ignore

      This option does not process the entries at all, but imports them into Jekyll verbatim. This may be useful if you wrote your entries in a Jekyll-compatible format.

Extension Options

This importer now supports some of the most common S9Y plugins.

  • includeentry

    Set this true to transclude entries like the includeentry plugin. The current, static content of the entry will be included. Future updates will not be synced.

  • excerpt_separator

    S9Y treats the regular post body as an excerpt, displaying the extended body only in the post details. Jekyll only shows the first paragraph of the post as an excerpt. This option allows you to restore the S9Y behavior: posts with extended body will have the specified separator added to their front matter, and you can modify your index layout to show the excerpts.

  • imgfig

    By default, this converts references to S9Y's media library into HTML figure tags. Set it to false to keep the original references, which you'll have to update manually.