There is one thing that most of us like about those fancy java IDE, the way the mark syntax errors on the fly. Also if you tried something like Intellij IDEA there are a lot more options regarding coding style, java doc checks, etc … that can be very useful.
After a few hours struggling with parenthesises, I finally managed to patch weblogger.el and xml-rpc.el to have those critical missing functionalities.
Now the default is to post as “Draft” when i use C-c C-n or C-c C-p so i can just prepare some text and save it for later. Changing publish state should be done explicitly with C-x C-s which calls the weblogger-publish-entry function, for not changing it C-c C-c.
Note that i said changing the published state, because at least on WordPress it switches from Draft to Published but also from Published to Draft with C-x C-s … i am unsure about the behaviour of other APIs.
I will have to do some work on this latter this week end …
Most importantly is the support for categories. It now display the categories in the header as “Keywords:” which you can set to one or many as a “, ” separated list. For example this post is “Keywords: Emacs, intarweb”.
The only thing i don’t see how to implement right now is auto-completion for the category names. Perhaps an emacs guru could have a look …
Another *minor* issue is that the API doesn’t provide any way to create new categories, which means that i *will* have to go on that slow web interface just for that. But how often do i need to change my categories anyway ?
Finally, on the would-be-nice list are clickable links in the header that open the preview page or post page. The URL is there, it just lack some hook in Emacs. Then attachment processing … the API seems to support it.
I also thought of markup support, but i guess it should just be installed in the blog site, processing “markup X” to HTML to “markup X” seems to be the perfect way to invoke Cthulhu bugs. So i would rather have mmm-mode support and use Emacs HTML capabilities.
I found that i almost don’t need HTML, at least on WordPress and for “just text” posts, because it formats paragraphs nicely without P tags.
This time the files are uploaded in my Emacs Hacks page.
Happy blogging !
Last week I found that even WordPress was difficult to access from my home, especially the web interface … so I decided to start looking for a blog software.
Being a KDE user I naturally went to kde-apps and found KBlogger. This application is a Kicker applet which appears as a big “Blog” button.
Setting it up was not too difficult but I had to find out that the URL of the blog is not enough, it needs to be pointed to xmlrpc.php.
In term of features it offers:
- fetching categories
- fetching your post for edit or deletion
- posting as draft or published
Unfortunately I couldn’t stand with:
- the “Blog” button takes too much room in my task-bar
- have to right click to have the list of posts .. then wait will it downloads from the server
- there is no caching
- if I press ESC in a dialog it cannot re-open any dialog, I have to remove and add the applet again
- no spell checking (Qt spell checking is said to mess with the output)
Unlike other Emacs features, this one was very easy to setup. The documentation on Emacs Wiki gives you the one or two commands you need and in 2 minutes I had all my entries fetched in Emacs.
So compared to KBlogger, it is very fast because it caches the posts and it supports Emacs spell checking. Since I am always in Emacs anyway writing a Blog post is just a shortcut away. It also makes posting code snippets or writing as you are coding very easy.
Unfortunately it doesn’t support categories yet, and attachments didn’t work …
Also the version I had didn’t work with WordPress very well, it could not upload the edited posts. I tracked down the issue to the format of the post date. Looks like WordPress is expecting a dateTime.iso8601 but receiving a string, a quick hack later and everything works as expected.
If I have time, I might just look into the category feature. It should not be too difficult anyway.
PS: I’ve attached the patched files. They include the patches from EmacsWiki that were needed, plus my own: dateTime format, and i escape strings in CDATA rather than url encoding (at first I thought the problem came from url encoding).