Skip to content

Instantly share code, notes, and snippets.

@steinarb

steinarb/.emacs Secret

Created May 19, 2024 11:50
Show Gist options
  • Save steinarb/e844560f5850612361431b4cdc1ffbec to your computer and use it in GitHub Desktop.
Save steinarb/e844560f5850612361431b4cdc1ffbec to your computer and use it in GitHub Desktop.
Config for using org2blog with wordpress blog and authinfo in the .netrc file (or any emacs auth source, really)
;; org-mode blogging setup
(when (and
(locate-library "org2blog")
(locate-library "metaweblog"))
(require 'org2blog)
(require 'auth-source)
(if (locate-library "ox-wp")
(load-library "ox-wp"))
(setq blog (car (auth-source-search :host "blog.mydomain.com")))
(setq org2blog/wp-blog-alist
(list
(list "my-blog"
:url "http://blog.mydomain.com/xmlrpc.php"
:username (plist-get blog :user)
:password (auth-info-password blog)))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment