Skip to content

Instantly share code, notes, and snippets.

@jasonbrooks
Forked from mojavelinux/steps.asciidoc
Last active December 18, 2015 05:29
Show Gist options
  • Save jasonbrooks/5733146 to your computer and use it in GitHub Desktop.
Save jasonbrooks/5733146 to your computer and use it in GitHub Desktop.
  1. git clone git://github.com/getpelican/pelican.git

  2. cd pelican

  3. python setup.py install

  4. pelican-import --wpfile -o ~/$output-location ~/Downloads/$wp-xml-file

  5. cd ~/$output-location

  6. for i in *.rst; do pandoc $i --no-wrap -f rst -t asciidoc post-content.html -o $i.adoc

  7. rename .rst.adoc .adoc *.rst.adoc

  8. use sed to cleanup [haven’t tested these sed bits myself yet]

    sed -i s/^image:/image::/ post-content.adoc
    sed -i s/^----.*/----/ post-content.adoc
  9. Mod, manually, to add document title, author and date (manual, atm)

    = Post title
    Jason Brooks
    2012-08-31
  10. Manually prepend date- to file names.

  11. copy to /archive dir

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment