tools: move upstream repo utility functions to version_resolver.py

This makes it possible to use them in other scripts as well.

Change-Id: I8aa76c1a9be91c56fd232a592ac41de5079eb3c7
Reviewed-by: Michael Bruning <michael.bruning@digia.com>
tools: add check_patches.py script for checking patch annotations

This script should be ran whenever adding new patches to our chromium
snapshot and makes sure we keep the upstream build functional.
Having clean patches is beneficial to keep it possible to upstream
patches to the Chromium project, and to keep an overview of our changes.

An annotation is not needed if the patch is adding files to the chromium
snapshot that were removed by take_snapshot.py, thus are already present
in the upstream repository.

In these cases the non-annotated patch will be ignored by the scripts.

Change-Id: I46605c559825d9da2653036e9a12a2a5730330a0
Reviewed-by: Michael Bruning <michael.bruning@digia.com>
tools: add reset option to patch_upstream.py

This patch makes it possible to reset the upstream chromium repository
to its baseline state.

Change-Id: Idff94a0f873e994716f77c83f4c5b79bcd48aec5
Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>