Well, the devs intended to switch to magnetic docking eventually, which means, as I understand it, that an object with an active docking module will snap onto a rail automatically if the rail is close enough.
So, that will do exactly this, once you get in range, and have wireless logic to...