How I met LyX Blogger

I was trying to find a way to edit a blog offline, and then I realized that it might be possible using LyX ( an open source document editor ). I found that I could use a program called LyX Blogger to upload an LyX document to WordPress.

What is LyX Blogger?

LyX Blogger makes it possible to upload a LyX document to WordPress. So you can edit your LyX document offline and then use LyX Blogger to upload the document. This post was made using LyX and uploaded using LyX blogger.


How to install LyX Blogger.

LyX Blogger is a program coded using python. So you need python. If you are using Linux or Mac OS X, python should be already in your system, but if you are using Windows you need to separately install python. If you have python, then you can go to the LyX Blogger site and download the latest version. Then follow the steps in to install LyX Blogger.

Here is how I did it on October 25th 2012 with Mac OS X 10.7.5.

1. Downloaded LyXBlogger_0.42.tar.gz from

2. Used the terminal to install LyX Blogger.
tar -zxvf LyXBlogger_0.42.tar
cd LyXBlogger_0.42.tar/INSTALL
python install

If you get an error at the last line do “su” and run the last line again.

How to use LyX Blogger.

Once you have made a document using LyX export the document to LyXHTML by File->Export->LyXHTML. Next type the following command in the folder that has the document you want to upload using terminal.
python -m lyxblogger fileName.xhtml

Then you will get a new window like below so that you can upload your document to WordPress.



Red line in WordPress.

If you do like above, the uploaded post will have a red underline. You can remove it by editing your post and then just press the update button without doing anything.

Moving to WordPress more easily

You can get the window from python directly from LyX. The method is written in the LyX Blogger user manual and I will not write it down here.