diff options
authorPaul Eggleton <>2017-08-29 11:00:29 +1200
committerPaul Eggleton <>2017-08-31 11:50:27 +1200
commit3d923d8c63b04e0ba8db997f82b738ece8696128 (patch)
parent9e8252c3af5778736faf4abb4e2810db5bcb86c1 (diff)
recipetool: create: make recently added branch/tag handling git specific
The branch and tag handling code that was recently added in OE-Core revs ecca596b75cfda2f798a0bdde75f4f774e23a95b and 3afdcbdc9a3e65bc925ec61717784ffec67d529d is specific to git, so only apply it when we're fetching from a git URL. Signed-off-by: Paul Eggleton <>
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/lib/recipetool/ b/scripts/lib/recipetool/
index 834633610a..4da745b732 100644
--- a/scripts/lib/recipetool/
+++ b/scripts/lib/recipetool/
@@ -518,7 +518,7 @@ def create_recipe(args):
# We need this checking mechanism to improve the recipe created by recipetool and devtool
# is able to parse and build by bitbake.
# If there is no input for branch name, then check for branch name with SRCREV provided.
- if not srcbranch and not nobranch and srcrev and (srcrev != '${AUTOREV}'):
+ if not srcbranch and not nobranch and srcrev and (srcrev != '${AUTOREV}') and scheme in ['git', 'gitsm']:
cmd = 'git branch -r --contains'
check_branch, check_branch_err ='%s %s' % (cmd, srcrev), cwd=srctree)
@@ -549,7 +549,7 @@ def create_recipe(args):
params['branch'] = srcbranch
srcuri = bb.fetch2.encodeurl((scheme, network, path, user, passwd, params))
- if storeTagName:
+ if storeTagName and scheme in ['git', 'gitsm']:
# Re-introduced tag variable from storeTagName
# Check srcrev using tag and check validity of the tag
cmd = ('git rev-parse --verify %s' % (storeTagName))