Add test for attr sorting.
Fix sort bug for manpages. #6.
Update changes.
Factor out the attr getting.