Skip to content

Posting to WordPress via the command-line

In February I was interested in posting to WordPress from the command-line, a possibility that I enjoyed when I wanted to apply some CLI-magic to some of my MediaWiki installations in the past.

I came across a great Perl module (WordPress::CLI) by Leo Charre. It depends on WordPress::XMLRPC

Another approach is to use the appfs FUSE filesystem, which uses WordPress’ support for the Atom Publishing Protocol. There’s another FUSE filesystem, BlogFS. This one depends on WordPress’ XML-RPC instead of its Atom interface.


    2 Comments ( Add comment / trackback )

    1. (permalink)
      Comment by Rowan Rodrik
      On January 5, 2011 at 01:14

      Trying to use BlogFS (version (1.0?) I downloaded from nixbit), I only get errors:

      Exception RuntimeError: 'maximum recursion depth exceeded while calling a Python object' in  ignored
      Exception RuntimeError: 'maximum recursion depth exceeded while calling a Python object' in  ignored
      BlogFS initiated
      Traceback (most recent call last):
        File "./blogfs.py", line 732, in 
          b.main()
        File "/usr/lib/python2.6/site-packages/fuse.py", line 736, in main
          d = {'multithreaded': self.multithreaded and 1 or 0}
        File "/usr/lib/python2.6/site-packages/fuse.py", line 889, in __getattr__
          m = self.methproxy(meth)
        File "/usr/lib/python2.6/site-packages/fuse.py", line 889, in __getattr__
          m = self.methproxy(meth)
        File "/usr/lib/python2.6/site-packages/fuse.py", line 889, in __getattr__
          m = self.methproxy(meth)
      

      fuse-python-0.2 and py-xmlrpc-0.8.8.3

    2. (permalink)
      Comment by Rowan Rodrik
      On December 3, 2011 at 00:33

      blogit.vim may be just what I’m looking for. After all, the reason why I want to be able to post from the command-line is so that I can write my posts with VIM. (No, I don’t like copy-paste, although, with xsel, it might not even be that painful.)

      Also, I’ve superficially compared blogit.vim with Vimpress and Vimrepress and decided that I like blogit.vim better.

    Post a comment

    (required)
    (required)

    Your email is never published nor shared.

    (optional)
    Allowed HTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>