Skip to content

Commit

Permalink
Updated the README with an example
Browse files Browse the repository at this point in the history
  • Loading branch information
Idorobots committed Aug 9, 2012
1 parent 60f2a7b commit e14e863
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.org
Expand Up @@ -111,6 +111,27 @@
- The parent for a page can be specified using =#+PARENT=. *C-c
t* again provides completion for the page name.

*** Using post templates
Custom post templates can be specified by modifying variables
=org2blog/wp-buffer-template= and =org2blog/wp-buffer-format-function=.

For example:

: (setq org2blog/wp-buffer-template
: "-----------------------
: #+TITLE: %s
: #+DATE: %s
: -----------------------\n")
:
: (defun my-format-function (format-string)
: (format format-string
: org2blog/wp-default-title
: (format-time-string "%d-%m-%Y" (current-time)))))
: (setq org2blog/wp-buffer-format-function 'my-format-function)

=org2blog/wp-new-entry= will now create buffers begining with a default
title and the current date.

*** Updating an existing post
To update a blog post, you can simply edit the content of the org
file and republish using ~org2blog~. The =POSTID= saved in the
Expand Down

0 comments on commit e14e863

Please sign in to comment.