On startup check that repository state are consistent and try to fix eventual issues.

This could be extended later by adding more consistency checks.
Improve again the output in case of errors.
Improve output of 'opam info' when the description is short (ie. only one line).
Improve the pin consistency checks, and consider that the pinned package is the one with max-version. I guess it would be better to give the option to the user to choose which is the corresponding version but no hurry.
Fix-up 'up-to-date' messages on 'opam update'.
Better message when the version of OPAM is not up-to-date.

It's maybe a bit harsh to beg the user to upgrade on every opam invocation, but I guess we could improve that with 1.0.0.

This should fix #382