Possible Duplicate:
Unix sort of version numbers
I have the following list of strings separated by commas:
2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 3.0, 3.1, 3.10, 3.11, 3.12, 3.13, 3.2, 3.3, 3.4, 3.5,3.6,3.7,3.8,3.9
I'm seeking a quick and elegant way to sort this list into:
2.0,2.1,2.2,2.3,2.4,2.5,3.0,3.1,3.2,3.3,3.4,3.5,3.6,3.7,3.8,3.9,3.10,3.11,3.12,3.13
Any ideas how this can be done in bash (using sort maybe)?