properly list and sort multiple -l matches

This is needed for globbing/regex support since multiple matches need
to be listed now.
providing no targets will list everything now

Works for both --search and --list.