From ec7067e85004c582a0e77c4c55fd9ce24c4bfdfb Mon Sep 17 00:00:00 2001 From: Antonio Ospite Date: Fri, 15 Jan 2016 20:15:40 +0100 Subject: [PATCH] smooth-dl.py: support using a local path for the Manifest file --- smooth-dl.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/smooth-dl.py b/smooth-dl.py index 44ef722..39785a4 100755 --- a/smooth-dl.py +++ b/smooth-dl.py @@ -118,11 +118,11 @@ def get_manifest(url, dest_dir): if not manifest_url.lower().endswith(('/manifest', '.ismc', '.csm')): manifest_url += '/Manifest' - if manifest_url.startswith('http://'): + if os.path.exists(url): + local_manifest_path = url + else: local_manifest_path = os.path.join(dest_dir, 'Manifest') download_file(manifest_url, local_manifest_path, "w") - else: - local_manifest_path = url manifest = etree.parse(local_manifest_path) -- 2.1.4