Refactor cli.py somewhat.

- Make handle_profiles(...) return a named tuple instead of just the profile
directory.
- Extract command line argument handling from mainloop(...).
- Instead of including profile information as part of command line arguments,
treat it as a separate variable/argument (not entirely sure this is the right
choice).
- Tweak profile functions' messages.
- Rename -w --wait-time to -r --refresh-time for greater clarity.