External Storage Moved. Again.

For those of you still in the habit of hard-coding in root paths like /sdcard and /mnt/sdcard, please be advised that on Jelly Bean devices, external storage is now at /storage/sdcard0. Links (not sure if they are symlinks or hardlinks) are set up so the legacy paths still work.

Of course, using the methods on Environment are the preferred way of dealing with this in production apps. However, if you are scripting anything (e.g., automated adb push from your desktop), you will need to take this into account. Notably, adb push does not seem to follow the links, so you will need to actually change the adb push commands (and, presumably, adb pull as well).

On the bright side, the fact that there is actually a digit in the name suggests that in some future Android release (K?), multiple volumes of external storage will be officially supported by the SDK, much to the delight of developers who have been hacking workarounds for getting at alternate data stores (e.g., USB thumb drives).