Questi sono i dati che desidero ordinare. Ma sort
considera il numerico come stringa, i dati non sono ordinati come mi aspettavo.
/ home / files / profile1
/ home / files / profile10
/ home / files / profile11
/ home / files / profile12
/ home / files / profile14
/ home / files / profile15
/ home / files / profile16
/ home / files / profile2
/ home / files / profile3
/ home / files / profile4
/ home / files / profile5
/ home / files / profile6
/ home / files / profile7
/ home / files / profile8
/ home / files / profile9
Voglio ordinare questo,
/ home / files / profile1
/ home / files / profile2
/ home / files / profile3
/ home / files / profile4
/ home / files / profile5
/ home / files / profile6
/ home / files / profile7
/ home / files / profile8
/ home / files / profile9
/ home / files / profile10
/ home / files / profile11
/ home / files / profile12
/ home / files / profile14
/ home / files / profile15
/ home / files / profile16
C'è un buon modo per bash script? Non posso usare lo script ruby o python qui.
sort -V
farebbe.