Sunday, January 11, 2009

Gmail migration script done!

Hello there again! Nothing like a little good olde' scripting to usher in the new year. As most of you will recall I was working on a script to migrate email from an existing imap server on to google app. The only thing that my script needed to do was transform folders into labels. Easy peasy I thought sure someone else has encountered this. Boy, was I wrong. I could not for the life of me find anything of the sort out there!

Well, no matter. I proceeded to create my own script from scratch and after about 2 hours my script could already scan my existing imap server, list all the folders and re-create them as labels on my gmail account! It was then that I stumbled across this piece of genius xiao duo so graciously left of the web. Their script was made to migrate emails from an existing gmail account to another gmail account. I found that the script they had complemented mine to a T! Talk about Laws of Attraction!! Great! All I had to do now was to transplant my script using my vim scalpel on to my script and faster than you can say Fedora 10's release name I had a working super duper gmail migration script!

Everything works as it should. About the only drawback I noticed with my script was that with TmNut's great connection, the connection timed out on me a few times and after restarting the script it started screening the folders right from the top again. Maddening! This is one of the improvements I have noted down, but for now everything works just fine. I can't attach any code here, so if for some reason you need the script just drop me a comment or a line here.

Catch ya laterz.

8 comments:

Anonymous said...

Hi,

I'd love to see a copy of the code as I need to do the same thing

arthur ____at____ clune.org

Cheers,

Arthur

worleyworks said...

this would be very handy.
worleyworks ____at____gmail.com
Thanks!
-Greg

Anonymous said...

Hi!
Do you plan to release this script? ;))

lowkster said...

teleneiko: I don't know. Maybe if I clean it up a bit and include the ability to read from a csv file. Quite easy peasy just that I am damn lazy :). You guys think this would be worth a release?

Unknown said...

Lowks: This is exactly what I was looking for. If you could send me a copy of it that would be great! mattannnelson ____at____ gmail
THANKS

Unknown said...

I would also like a copy of the script

hansenll___at___excite.com

thanks....

Unknown said...

Could I request a copy as well?

dmartinez____at____mcatsolutions.com

Thanks so much!

Unknown said...

We have created a simple web interface that does all the migration in the background. Feel free to give it a try here:

https://apps.improffice.com/migrationbeta/