If it is a true cube with same-length edges, the same texture on all faces, AND the texture is symmetrical on both axes, doing it in maya will likely be easiest and most efficient. You could do a single animation of it flipping forward, and just set the rotation of the object to face the direction of movement before playing the animation, then update the position after the animation finishes.
If one or more of those three conditions are not true, it would be tricky to do it in maya, and you'll probably want to do it dynamically. This question is about how to do that specifically, and includes an explanation as well as example code in js. http://answers.unity3d.com/questions/144830/how-to-rotate-around-object-axis.html