Just wanted to share a simple scripted for quickly baking and exporting animations in Maya. There's quite a few clicks to go through the process, even more so if there is no proper layering for meshes etc, but with this script only one is needed!
select `ls -typ joint`;
select -tgl `ls -typ mesh`;
Basically, it selects all joints and bakes them (from your settings), adds all meshes to the selection, inverts the selection, deletes all unnecessary objects (controls etc.) and exports it all.
Please do save your scene as another file before doing this as it's quite destructive (I believe :poly122:)