Avoid touching $HOME when displaying help or version

Currently any execution of lgogdownloader touches $HOME, even if the
user only requested help or the version number. This fixes main() to
handle --help and --version before doing anything to the filesystem.

This also helps some build environments where $HOME is undefined
(e.g. the Debian build platform).

Signed-off-by: Stephen Kitt <steve@sk2.org>