re-wrote sort.py, doesn't interpret tags