Hi Guys good day. What is the best way to sort a file version?

ie
4.06.045.07
3.06.045.07
4.12.45.074
4.06.04.207

so it would be this order:

3.06.045.07
4.06.04.207
4.06.045.07
4.12.45.074

Any inputs are much appreciated.

thanks.