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

Unified Diff: scripts/slave/recipe_modules/ios/api.py

Issue 1145733003: ios: Allow bot configs to set extra env variables (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@master
Patch Set: Provide a default self.__config['env'] Created 5 years, 7 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
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/ios/example.expected/basic.json » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/slave/recipe_modules/ios/api.py
diff --git a/scripts/slave/recipe_modules/ios/api.py b/scripts/slave/recipe_modules/ios/api.py
index 671f0bb6c85acb39ac946166a3f165ec4946116d..1c90295104387f4f447cec841d869dd55ee76fae 100644
--- a/scripts/slave/recipe_modules/ios/api.py
+++ b/scripts/slave/recipe_modules/ios/api.py
@@ -123,13 +123,13 @@ class iOSApi(recipe_api.RecipeApi):
self.__config['GYP_DEFINES']['component'] = 'static_library'
self.__config['GYP_DEFINES']['OS'] = 'ios'
- # Because build configs are only required to specify "triggered bots" or
- # "tests", one of them may not be specified. In order to simplify the code
- # that uses the values of self.__config, here we default them both to empty
- # values of their respective types, so in other places we can iterate over
- # them without having to check if they are in the dict at all.
+ # In order to simplify the code that uses the values of self.__config, here
+ # we default to empty values of their respective types, so in other places
+ # we can iterate over them without having to check if they are in the dict
+ # at all.
self.__config['triggered bots'] = self.__config.get('triggered bots', {})
self.__config['tests'] = self.__config.get('tests', [])
+ self.__config['env'] = self.__config.get('env', {})
# Elements of the "tests" list are dicts. There are two types of elements,
# determined by the presence of one of these mutually exclusive keys:
@@ -224,6 +224,9 @@ class iOSApi(recipe_api.RecipeApi):
'LANDMINES_VERBOSE': '1',
}
+ # Add extra env variables.
+ env.update(self.__config['env'])
+
if self.compiler == 'xcodebuild':
env['GYP_GENERATORS'] = 'xcode'
env['GYP_GENERATOR_FLAGS'] = 'xcode_project_version=3.2'
« no previous file with comments | « no previous file | scripts/slave/recipe_modules/ios/example.expected/basic.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698