Skip to content

Instantly share code, notes, and snippets.

@nabucosound
Last active December 18, 2015 18:30
Show Gist options
  • Save nabucosound/5826535 to your computer and use it in GitHub Desktop.
Save nabucosound/5826535 to your computer and use it in GitHub Desktop.

Writing to a Nomadblog post

Steps

  1. Copy the template.rst into a new source reStructuredText file:

    cp template.rst src.rst
    
  2. After the file has been edited with your post contents, convert it to HTML:

    workon rst
    rst2html.py --link-stylesheet --initial-header-level=2 src.rst > dst.html
    
  3. Give a final check out using your default browser:

    open dst.html
    
  4. Edit the HTML version to remove tags like <html>, <head>, <body>, <div>:

    vim dst.html
    
  5. Copy to your clipboard (Mac OS X way):

    cat dst.html | pbcopy
    
  6. Go to your Django admin to create a new post and paste clipboard to proper fields

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