emacs: clean up init file and add more modes

Add navigation-by-categories, sort packages in a more logical order and
add self-installed packages not recorded in the init file before.