fix path with url

This commit is contained in:
Valentin CZERYBA 2023-03-08 22:41:35 +01:00
parent 77e61ef571
commit 4d073e0254

View File

@ -165,11 +165,11 @@ if __name__ == '__main__':
url = o.geturl().replace(":///", "://") url = o.geturl().replace(":///", "://")
if args.js is False: if args.js is False:
script = getScriptCss(url, True, False, logger) script = getScriptCss(url, True, False, logger)
downloadPage(script, "{0}/{1}".format(args.dir, "dists/js"), logger) downloadPage(script, "{0}/{1}/{2}".format(args.dir, o.path, "dists/js"), logger)
if args.css is False: if args.css is False:
css = getScriptCss(url, False, True, logger) css = getScriptCss(url, False, True, logger)
downloadPage(css, "{0}/{1}".format(args.dir, "dists/css"), logger) downloadPage(css, "{0}/{1}/{2}".format(args.dir, o.path, "dists/css"), logger)
if args.html is False or args.img is False: if args.html is False or args.img is False:
webpage = getUrlPage(url, logger) webpage = getUrlPage(url, logger)
@ -178,6 +178,4 @@ if __name__ == '__main__':
if args.img is False: if args.img is False:
page_src = getImg(webpage, logger) page_src = getImg(webpage, logger)
downloadPage(page_src, "{0}/{1}".format(args.dir, "img"), logger) downloadPage(page_src, "{0}/{1}/{2}".format(args.dir, o.path, "img"), logger)
#