Blog ping
One drawback with blogger is that it can only ping weblogs.com. But I want to ping some other index sites too. One way is to go to each site and ping manually, but thats to much work. Another solution is to have a script or something that you run after each time you have written a blog entry.
It hit me that blogger can send a mail each time you enter a new blog entry. So I wrote a python-script yesterday that is trigged by these mails an ping sites using XML-RPC. My script, blogping, reads a config file and ping all services listed in the config file. Then I added an email alias in my email server that run the script when a mail comes in. Last I registered the mail address in blogger.
The alias looks like this in postfix:
blogmail: |"/opt/local/bin/blogping.py -c /opt/local/etc/configfile"
The result of the pings are logged using syslog. You can download the script from here. Run the script with the argument -h to get instructions. You do not have to trig it using mail, it can be executed stand alone.
I have tested the script in both Ubuntu Dapper and Edgy.
It hit me that blogger can send a mail each time you enter a new blog entry. So I wrote a python-script yesterday that is trigged by these mails an ping sites using XML-RPC. My script, blogping, reads a config file and ping all services listed in the config file. Then I added an email alias in my email server that run the script when a mail comes in. Last I registered the mail address in blogger.
The alias looks like this in postfix:
blogmail: |"/opt/local/bin/blogping.py -c /opt/local/etc/configfile"
The result of the pings are logged using syslog. You can download the script from here. Run the script with the argument -h to get instructions. You do not have to trig it using mail, it can be executed stand alone.
I have tested the script in both Ubuntu Dapper and Edgy.
Comments
Perl and WWW::Mechanize are really nice for that sort of thing.
Another reason, of course, for not doing it your way is that I don't have a mail server handy.
If you using fetchmail and a mailservice (like lysator) that support adding a postfix (not the software) to your username you can send mail from blogger to user+blog@foo.com and let fetchmail run the script.
I think it is only a matter of time until blogger/google supports ping to arbitrary sites.