This commit is contained in:
EstrellaXD
2022-05-19 19:47:46 +08:00
parent 1f7ba07570
commit 4ee3c1863e
2 changed files with 3 additions and 3 deletions

View File

@@ -10,7 +10,7 @@ import re
class CollectRSS:
def __init__(self, config, info):
self.bangumi_list = []
with open("rule.json") as f:
with open("/app/rule.json") as f:
self.rules = json.load(f)
rss = requests.get(config["rss_link"], 'utf-8')
soup = BeautifulSoup(rss.text, 'xml')

View File

@@ -10,7 +10,7 @@ config_path = "/config/config.json"
info_path = "/config/bangumi.json"
host_ip = os.environ["HOST"]
sleep_time = os.environ["TIME"]
user_name = os.environ["USER_NAME"]
user_name = os.environ["USER"]
password = os.environ["PASSWORD"]
rss_link = os.environ["RSS"]
download_path = os.environ["DOWNLOAD_PATH"]
@@ -30,7 +30,7 @@ def create_config():
with open(config_path, "w") as c:
json.dump(config, c, indent=4, separators=(',', ': '), ensure_ascii=False)
if not os.path.exists(info_path):
bangumi_info = [{"title":"simple","season":""}]
bangumi_info = []
with open(info_path, "w") as i:
json.dump(bangumi_info, i, indent=4, separators=(',', ': '), ensure_ascii=False)