summaryrefslogtreecommitdiff
path: root/scripts/lib
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2015-12-22 17:03:13 +1300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-12-22 16:44:03 +0000
commit29833828a90c8433af3b231b50e99cd97edf19ff (patch)
tree75b98a95b47646b0df9429d0e60e16241cb79b6b /scripts/lib
parent83707d1334fb094fd1877bcfd07a83866601048a (diff)
downloadopenembedded-core-29833828a90c8433af3b231b50e99cd97edf19ff.tar.gz
openembedded-core-29833828a90c8433af3b231b50e99cd97edf19ff.tar.bz2
openembedded-core-29833828a90c8433af3b231b50e99cd97edf19ff.zip
devtool: status: list recipe file within workspace if one exists
If a recipe in the workspace actually exists as a file within the workspace (e.g. after doing "devtool add" or "devtool upgrade") then show the path to the recipe file on the status line for the recipe. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib')
-rw-r--r--scripts/lib/devtool/standard.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index c710c16635..ed9e793d4a 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -26,6 +26,7 @@ import argparse
import argparse_oe
import scriptutils
import errno
+import glob
from collections import OrderedDict
from devtool import exec_build_env_command, setup_tinfoil, check_workspace_recipe, use_external_build, setup_git_repo, recipe_to_append, DevtoolError
from devtool import parse_recipe
@@ -1168,7 +1169,16 @@ def status(args, config, basepath, workspace):
"""Entry point for the devtool 'status' subcommand"""
if workspace:
for recipe, value in workspace.iteritems():
- print("%s: %s" % (recipe, value['srctree']))
+ bbfile = os.path.basename(value['bbappend']).replace('.bbappend', '.bb').replace('%', '*')
+ recipefile = glob.glob(os.path.join(config.workspace_path,
+ 'recipes',
+ recipe,
+ bbfile))
+ if recipefile:
+ recipestr = ' (%s)' % recipefile[0]
+ else:
+ recipestr = ''
+ print("%s: %s%s" % (recipe, value['srctree'], recipestr))
else:
logger.info('No recipes currently in your workspace - you can use "devtool modify" to work on an existing recipe or "devtool add" to add a new one')
return 0