Another possible, more green solution would be to move to biodiesel to replace the existing fossil diesel. If electric cars more or less fully replace gasoline cars (which I expect to happen), and electric can be used for lighter duty short haul trucking, we can reduce the fossil fuel footprint to the point where biodiesel might actually be feasible.
The trick, then, is getting that clean fuel cost-competitive with fossil diesel.