Sunday

Post to your blog at blogger.com from gVIM.

Tested on windows only.
Requirements:
1.python installed.
2. Google Data APIs - gdata-python-client
can be downloaded from here : http://gdata-python-client.googlecode.com/files/gdata.py-1.0.10.latest.zip

Installation :
1.Install python
2.Download gdata-python-client unpack and run "setup.py install"
3.download bg01.zip unpack bg.py and place in any folder mentioned in %PATH%
4. add this line to your _vmrc file :
nnoremap <Leader>blog :! bg.py --f %:p --u my@email.com --p inline<cr>
where my@email.com is your email registered on blogger.com

--p inline - means that password will be asked on every posting to blog , you can specify it in this line if you want.
Than script will not be asking every time.
nnoremap <Leader>blog :! bg.py --f %:p --u my@email.com --p mypassword<cr>

Using:
When you want to post current file to blog : just hit '\blog' enter password and new blog entry will be created.
I added post here how to create blog with syntax-highlighted source code.
Please leave a word or bug :) or questions,concerns,comments,jockes here

more...

4 comments:

Anonymous said...
This comment has been removed by the author.
root said...

Hi,

I think you can try to download
http://effbot.org/media/downloads/elementtree-1.2.6-20050316.tar.gz
ElementTree manually , unpack and run installation :
$ python setup.py install


I will check thi out on my ubuntu box.

Anonymous said...

Sorry for the deleted comment. The problem was related with versions of python-gdata and python-elementtree. For ubuntu users, the versions in hardy heron are needed.

python-elementtree (1.2.6-11ubuntu1)
python-gdata (1.0.9-1)

Albie said...

On line 39 of bg.py, you ask for an inline password using sys.stdin.readline(). I recommend changing it to getpass.getpass() instead - it functions similar to readline in that it fills a variable with a string, but it does not display the password on stdout (the screen).

You will have to import getpass for this function, it is part of the standard python 2.5.

test smtp server with powershell

Send-MailMessage -SMTPServer smtp.domain.com -To [email protected] -From [email protected] -Subject "This is a test email" -Body ...