Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2428)

Unified Diff: build/android/play_services/utils.py

Issue 1418573010: Enable downloading Google Play services via deps hook (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: build/android/play_services/utils.py
diff --git a/build/android/play_services/utils.py b/build/android/play_services/utils.py
index 94e684bccb823ead280484c9229d6c19c09fc444..e410fb6dcd9f6ea117db19cbdca86046af83ecd3 100644
--- a/build/android/play_services/utils.py
+++ b/build/android/play_services/utils.py
@@ -18,6 +18,11 @@ import zipfile
sys.path.append(os.path.join(os.path.dirname(__file__), os.pardir))
from devil.utils import cmd_helper
+from pylib import constants
+
+sys.path.append(os.path.join(constants.DIR_SOURCE_ROOT,
+ 'third_party', 'colorama', 'src'))
+import colorama
_CONFIG_VERSION_NUMBER_KEY = 'version_number'
@@ -37,6 +42,13 @@ class DefaultsRawHelpFormatter(argparse.ArgumentDefaultsHelpFormatter,
pass
+def EmphasizeMessage(message):
dgn 2015/10/28 13:54:33 Should I make a proper stream handler for the logg
jbudorick 2015/10/28 14:08:25 Have warnings print yellow and errors print red? I
dgn 2015/10/28 14:27:13 Should I put that in pylib?
jbudorick 2015/10/28 14:28:53 Yeah, that'd be great. You may see it in the test
jbudorick 2015/10/28 14:29:31 (specifically, pylib/utils/)
dgn 2015/10/28 16:32:58 Addressed in https://codereview.chromium.org/14185
+ # pylint warning: does not see members added dynamically in the constructor.
+ # pylint: disable=no-member
+ return (colorama.Fore.YELLOW + colorama.Style.DIM + message +
+ colorama.Style.RESET_ALL)
+
+
def FileEquals(expected_file, actual_file):
'''
Returns whether the two files are equal. Returns False if any of the files

Powered by Google App Engine
This is Rietveld 408576698