From e09dba53291ce99d7c35b407b93b912f30d50839 Mon Sep 17 00:00:00 2001 From: midoks Date: Tue, 13 Apr 2021 12:57:58 +0800 Subject: [PATCH] up --- plugins/aria2/index.py | 10 +++++----- plugins/zimg/index.py | 6 ++++++ 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/plugins/aria2/index.py b/plugins/aria2/index.py index 380c96b09..48ce32695 100755 --- a/plugins/aria2/index.py +++ b/plugins/aria2/index.py @@ -59,11 +59,11 @@ def initDreplace(): if not os.path.exists(initD_path): os.mkdir(initD_path) - # initd replace - content = mw.readFile(file_tpl) - content = content.replace('{$SERVER_PATH}', service_path) - mw.writeFile(file_bin, content) - mw.execShell('chmod +x ' + file_bin) + # initd replace + content = mw.readFile(file_tpl) + content = content.replace('{$SERVER_PATH}', service_path) + mw.writeFile(file_bin, content) + mw.execShell('chmod +x ' + file_bin) aria2_path = getServerDir() + '/aria2' mw.execShell('mkdir -p /tmp/download') diff --git a/plugins/zimg/index.py b/plugins/zimg/index.py index 3c33446b4..4c84e8969 100755 --- a/plugins/zimg/index.py +++ b/plugins/zimg/index.py @@ -59,6 +59,12 @@ def initDreplace(): if not os.path.exists(initD_path): os.mkdir(initD_path) + # initd replace + content = mw.readFile(file_tpl) + content = content.replace('{$SERVER_PATH}', service_path) + mw.writeFile(file_bin, content) + mw.execShell('chmod +x ' + file_bin) + return file_bin