summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcw1.shin <cw1.shin@samsung.net>2017-07-07 15:21:32 +0900
committer이창현/개발플랫폼팀/L3/ <leechwin.lee@samsung.com>2017-07-07 16:13:15 +0900
commitacdbf38308a4d40cc85ce75d57eb36da2a01d824 (patch)
treeebd65dc426d8d847df6586fb682f2094850d7880
parentee40fe749f58244ad6747e41e85b136e9ae92c26 (diff)
downloadtic-core-acdbf38308a4d40cc85ce75d57eb36da2a01d824.tar.gz
tic-core-acdbf38308a4d40cc85ce75d57eb36da2a01d824.tar.bz2
tic-core-acdbf38308a4d40cc85ce75d57eb36da2a01d824.zip
(TPE-106) fix the filter in the recipe import process.
- http/https support in recipe import process. Change-Id: I25e6dde6dd9b52af1b149c8113b7e83d1c551192 Signed-off-by: cw1.shin <cw1.shin@samsung.net>
-rw-r--r--tic/parser/recipe_parser.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tic/parser/recipe_parser.py b/tic/parser/recipe_parser.py
index 60f753d..580d515 100644
--- a/tic/parser/recipe_parser.py
+++ b/tic/parser/recipe_parser.py
@@ -39,6 +39,7 @@ ARCH_OPTION = '-A %s'
PACK_TO_OPTION = '--pack-to=%s'
ARCH_OPT_PATTERN = re.compile(configmgr.regularexp['arch_option_pattern'])
PACK_TO_OPT_PATTERN = re.compile(configmgr.regularexp['pack_to_option_pattern'])
+HTTP_HTTPS_PROT = re.compile('^http[s]?')
#TODO: Must be deleted after consolidating base repository
BASE_REPO_URLS = set(['http://download.tizen.org/snapshots/tizen/base/latest/repos/arm/packages/',
@@ -151,7 +152,7 @@ class RecipeParser(object):
# default recipe
if data['url'] == DEFAULT_RECIPE_NAME:
self.recipes[data['url']] = default_recipe.get_default_recipe()
- elif data['url'].startswith('http:/'):
+ elif HTTP_HTTPS_PROT.match(data['url']):
with contextlib.closing(urllib2.urlopen(data.get('url'))) as op:
self.recipes[data['url']] = yaml.load(op.read())
else: