revert: add support for reverting subrepos
Reverting a subrepo is done by updating it to the revision that is selected on
the parent repo .hgsubstate file.
* ISSUES/TODO:
- reverting added and removed subrepos is not supported yet.
- reverting subrepos is only supported if the --no-backup flag is used (this
limitation will be removed on another patch).
- The behavior of the --all flag has been changed. It now reverts subrepos as
well. Note that this may lead to data loss if the user has a dirty subrepo.
commands: move bundle type validation earlier
Checking the bundle type late in the command's execution can mean
that we do work for a long time before complaining about incorrect
user input and aborting. Guess how I discovered this.