This Eclipse plugin adds sorting to the Edit menu. You can sort case sensitively, case insensitively, numerically, and reverse the selected text. The numerical sort assumes that the first set of characters on each line is a number and sorts accordingly.
Installing and Using Sort It
Download the plugin and unzip it into your plugins directory. The zip file contains a directory called com.teaminabox.sortit_x.y.z, which when placed under the Eclipse plugins directory will add the Sort It plugin to your Eclipse install. You need to restart Eclipse to make the plugin available.
Enable the plugin by customising the perspective and adding the actions under the following menu path: Window | Customize Perspective | Commands and checking the Sort It check box in the left most column.
To sort lines of text, select them, and select the appropriate sort from the Sort It menu item under th edit menu or popup menu. If you don?t select any lines then the sort will be performed on the entire file CTRL+SHIFT+F will perform a case sensitive sort.
Know click for more information.
Recommend the tutorial