Sort a text file

Linux, sort

To sort a file numerically by the second field, where each field is seperated by a ':', invoke ... sort.

hostname:$ sort -t':' -nk2 file

Comments powered by Disqus

Copyright 2010. All Rights Reserved.