From 2a81631d563015905915b8c6fff4729f74369896 Mon Sep 17 00:00:00 2001 From: Joshua Watt Date: Thu, 18 Apr 2019 21:57:17 -0500 Subject: resulttool: Load results from URL Adds support for resulttool to load JSON files directly from a http:// or https:// URL (From OE-Core rev: 8e2f0257e1e438b88e4298438d5bae5f7c3c0a7a) Signed-off-by: Joshua Watt Signed-off-by: Richard Purdie Signed-off-by: Armin Kuster Signed-off-by: Richard Purdie --- scripts/lib/resulttool/store.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts/lib/resulttool/store.py') diff --git a/scripts/lib/resulttool/store.py b/scripts/lib/resulttool/store.py index e4a0807528..acdfbd94fd 100644 --- a/scripts/lib/resulttool/store.py +++ b/scripts/lib/resulttool/store.py @@ -29,7 +29,7 @@ def store(args, logger): try: results = {} logger.info('Reading files from %s' % args.source) - if os.path.isfile(args.source): + if resultutils.is_url(args.source) or os.path.isfile(args.source): resultutils.append_resultsdata(results, args.source) else: for root, dirs, files in os.walk(args.source): @@ -92,7 +92,7 @@ def register_commands(subparsers): group='setup') parser_build.set_defaults(func=store) parser_build.add_argument('source', - help='source file or directory that contain the test result files to be stored') + help='source file/directory/URL that contain the test result files to be stored') parser_build.add_argument('git_dir', help='the location of the git repository to store the results in') parser_build.add_argument('-a', '--all', action='store_true', -- cgit v1.2.3-54-g00ecf