Categories
Apple eMail Google Linux OSX UNIX

How to copy Mails from iCloud to GMail

You can use the fabulous imapsync tool to copy mails between IMAP servers. For example you can copy a certain folder from Apple’s iCloud to Google’s gmail:

imapsync 
--noauthmd5 --ssl1 --ssl2
--host1 mail.me.com --user1 'your.icloud.name'
--host2 imap.gmail.com --user2 'your.gmail.name@googlemail.com'
--folder 'your/folder/to/be/copied' --sep1 '/'
--prefix1 '' --prefix2 '[Google Mail]' --sep2 '/'

The important parts here are the user names for the IMAP servers. Note that you need to generate an application specific password, if you are using Google two factor authentication! Also important is the “[Google Mail]” IMAP prefix.

Edit: It seems gmail has a weird interpretation of all the IMAP folders and stuff. Since they are using labels, the above script might create a weird label for the copied emails, but they will be there nevertheless!

Categories
Apple MobileMe OS X

Pimping MobileMe #1: Expiration dates on folders

Well, MobileMe does not yet support the expiration of mails in folders. Especially for mailing lists, I want this feature. After let’s say 90 days the mails should be automatically deleted. I do not need to store mailing list contents for longer. So I took the nice tool imapfilter and wrote a config file that expires old mails from a selection of folders. I installed a cronjob on my web server that now automatically calls imapfilter every night. The config file (~/.imapfilter/config.lua) looks like this:

Myaccount = IMAP {
   server = ‘mail.me.com’,
   username = ‘your.name@me.com’,
   password = ‘yourpassword’,
   ssl = ‘tls1’
}


folders = {‘folder1’, ‘folder2’, ‘folder3’}


for k,folder in pairs(folders) do
   foldername = ‘Mailinglists/’ .. folder
   results = myaccount[foldername]:is_older(90)
   myaccount[foldername]:delete_messages(results)
end

My mailing lists are hosted under a sub-folder called “Mailinglists”, as you can notice in the config file above. You can tweak this to your liking. It might also be useful to set different expiration dates. It’s easy to augment the lua script to do so.
Categories
Apple Slashdot Storage

Do magnetic hard drives go the way of the poodle?

There is an article over at Slashdot about the possible decline of the traditional hard disk. We now have tablets like the iPad and its clones having only solid state / flash memory, and the new MacBook Air reaching a price point which is a direct competition to Apple’s entry level MacBook. This really might be a sign for solid state storage to have reached the ordinary customer, outside of MP3 players, cameras and smartphones. The discussion on Slashdot is erratic and irrational, as usual, but some interesting points are also made. The thing those people are missing though is: This is again another Apple strategy. Apple can allow to enter a mass market first. They have loads of money, their products are still priced at the high point. They don’t compete with the low level market. So offering a 11.6″ laptop with a meagre 64 GiB of storage is doable for Apple. Sure, most geeks will say: What a puny machine! But again, as with the iPad, Apple can drive markets that don’t care about computing power and loads of disk storage: Your mom, my mom and millions of other people might be happy with such a machine, that only 5 years ago would have been more computer than you’d ever needed. In a significantly larger form factor.
And in 5 years you probably won’t see any laptop with a spinning drive anymore. Apple is just very early to the game, as usual. Remember the floppy-less iMac? They never were the first, but they were always quick to pick up and set trends. Also, what most geeks at Slashdot don’t understand: Yes, Apple is fashion. Apples is expensive. But that’s exactly why their product sell. Is it a good thing? Probably not. But that’s how the market works: fashion sells. Also their laptops are incredibly well manufactured, in my opinion. Not without flaws, but much better than most devices I held in my hand.

Categories
Apple iPad

How to downgrade an iPad from 4.2beta to 3.2.2

When trying to downgrade an iPad from 4.2beta to 3.2.2 directly via iTunes, I just get a non-descript error message. However, there is a nice howto out there, which describes this.

Categories
Apple iWork OS X

Description of Apple’s Keynote file format

What a nice surprise. Apple has actually documented the Keynote file format. Sadly, as far as I can see, there is no import/export capability in either PowerPoint nor OpenOffice.org Impress. That would be a nice feature. But it’s good that Apple does document the format. Since it is XML, it is easy to parse. However the hard part is always the semantics, not the syntax…

Categories
Apple Linux

MobileMe bugs: Image upload with Linux based browsers impossible

Well, the MobileMe gallery upload seems to only like Mac browsers. I have only my SuSE box here, so I tried to upload using Chrom 5.0 and Firefox 3.5. No luck. Both browsers throw errors. Just like this:

So far, I cannot find any documentation on this behaviour. I would have assumed that either FFox or Chrome would work. MobileMe on OS X says it supports FFox and Safari. But since Safari is not available on Linux, I thought I might try FFox and Chrome. Now waiting for a MobileMe chat support guy. I doubt they are educated enough to actually help me…


Update: The chat guy was friendly, and had one hint: update to FFox 3.6. I was still on 3.5. And sure enough: now the upload works. Only one file at a time, though. But I found out even more on my own. It seems all the images are accessible from your iDisk as well. They are stored in Web/Sites/_gallery/id. Where id is the number of your gallery. However, you cannot just upload pictures there. Every image needs to be put in a separate directory. Every directory must then have the following files:


exif.json
large.jpg
medium.jpg
square.jpg
web.jpg


The exif.json is obviously a JSON style EXIF data block, e.g. like this:
{“data”:{“infoSensing”:”One-chip color area sensor”,”infoExposure”:”Normal program”,”infoExposureIndex”:”–“,”infoFNumber”:”2.8″,”infoDistance”:”–“,”infoGPSLongitude”:”8° 15&#39 35.40″ E”,”infoWidth”:”2,048 pixels”,”infoName”:”IMG_0133.jpg”,”infoDigitizedDate”:”Thu, 19 Aug 2010 12:18:20 PDT”,”infoFocalLength”:”3.85 mm”,”infoHeight”:”1,536 pixels”,”infoExposureTime”:”0.003846154″,”infoGPSLatitude”:”50° 0&#39 5.40″ N”,”infoAperture”:”f/3.0″,”infoMetering”:”Average”,”infoShutter”:”1/260″,”infoSize”:”1022.27 KB”,”infoBrightness”:”–“,”infoCameraModel”:”iPhone 3GS”,”infoMaxAperture”:”–“,”infoCameraMake”:”Apple”,”infoExposureBias”:”–“,”infoFlash”:”32″,”infoOriginalDate”:”Thu, 19 Aug 2010 12:18:20 PDT”,”infoGPSAltitude”:”115.00 m”,”infoISOSpeed”:”64″,”infoLightSource”:”–“,”infoSoftware”:”4.0.2″},”status”:1}
This should be easily created by a short shell script, using “exiftool -s image.jpg” and some awk magic. The image files in the folder are:

large.jpg: 2048×1536 (original resolution? at least for iPhone 3GS)
medium.jpg: 427×320 (approx. iPhone screen resolution)
square.jpg: 160×160 (thumbnail)
web.jpg: 1024×768

For portrait, I assume that the width and height are swapped. Have not checked this yet. Later, I will try to whip up a bash or Python script which produces these files automatically from a list of input images. Let’s see if this works.

Oh yes, one more thing: In Linux you can easily mount the iDisk with “wdfs  http://idisk.me.com/your-id iDisk/
“.

Update 2: A quick check revealed that the iDisk interface is quasi read-only. Writing new albums or pictures there will not show up in the gallery itself. That would have been too nice. So I guess this is only possible via the (unpublished?) HTTP API of MobileMe itself. Just like the Picasa API for uploading and manipulating photos. But it seems the API is quite hard to decipher, which is sad, given that Google practically documents all their APIs and encourages mashups and websites using their services.
Categories
Apple Gimp OS X X11

Getting halfway sane mouse click behaviour in Gimp on OS X

I can definitely recommend the X11 packages from the XQuartz project. They are more up to date than the X11 server shipped with OS X. Also, the Gimp packages over at Lisanet are fantastic, too. However, the default click behaviour of X11 or rather quartz-wm is not optimal, especially for the Gimp. Usually I like focus follows mouse, but for an interface like the Gimp, it does not make sense. You always inadvertendly focus on an image, that you did not want to focus. Since there is no delayed ffm mode in quartz-wm, I opted for click-to-focus instead. However, quartz-wm swallows mouse clicks on inactive windows. This is also not worthwile for the Gimp with it’s extra tool palette windows. So the soluation is: click-through combined with click-to-focus. Easy:


defaults write org.macosforge.xquartz.X11 wm_click_through -bool true
defaults write org.macosforge.xquartz.X11 wm_ffm -bool false

In newer releases you can set this also from the preferences (⌘,). If you are using the X11 version shipped with OS X, you can most probably just replace org.macosforge.xquartz.x11 with com.apple.x11.

Categories
Apple Google

iCal woes: Event invite for Google Calendar is never sent

Ok, here is another bugger that annoyed me for quite some time: I am using Google Calendar as my main method of dealing with appointments and shared calendars. I use the mostly fabulous Apple iCal for managing those dates. However, if I create an event to be shared with several people, and I try to send an invitation to those people, this doe not work. In the event properties, I enter a list of Email adresses, hit “Send” and it never gets sent. The event is marked as “waiting for answers”, though. But that will never happen… So I have to fire up the Google Calendar website and resend the invitations manually. Bit annoying.

I haven’t found a correct problem description so far for this in the discussion boards over at Apple, but I’ll update this post if I find a bug description or some workaround. However, a preliminary search yields several problems relating to iCal and event invitations, but also with event invitations on Google calendars.
Categories
Apple iPhone

Mystery calls by my iPhone

In the last couple of days my iPhone made a couple of ghost calls. I.e. it called some people from my address book, without me doing the actual calls. I think I found the reason for that now. When you hit the home button for several seconds, an iPhone 3GS with iOS 3.x or 4.x will go into voice command mode. This even works when the phone is keylocked. The voice function is not so robust and will misinterpret quite a few background sounds, noises and voices for commands. I couldn’t yet make 100% sure that this is how it happened, but it seems to be the only possibility so far, since my phone is always keylocked, when I carry it in my pocket. So I figure the home button was accidentally pressed, and thus the voice command was activated. Will try to investigate this further…

Categories
Apple iPhone OS X

me.com woes

I have been using me.com for a while now, and am relatively happy with it. The automatic sync of the data between my work laptop and my iPhone is absolutely priceless. Now I’ve upgraded to the family account to share the (for my needs) ample 40 GB with two friends. Turns out, the other two accounts can only get 5 GB of storage. Ouch. That sort of sucks. Right now, 10 GB cannot be used at all, cause they are reserved for two more people. Why am I then paying for the extra storage anyhow?