From c9136fa76682af8bf95ba805d2880fdf9104ba8a Mon Sep 17 00:00:00 2001 From: frxz751113 <156018267+frxz751113@users.noreply.github.com> Date: Thu, 12 Sep 2024 23:40:04 +0800 Subject: [PATCH] =?UTF-8?q?Update=20=E9=85=92=E5=BA=97=E6=BA=90.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- py/酒店源.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/py/酒店源.py b/py/酒店源.py index f6e6e92..b9f45f3 100644 --- a/py/酒店源.py +++ b/py/酒店源.py @@ -1124,15 +1124,14 @@ with open('酒店优选.txt', 'w', encoding="utf-8") as file: import datetime now = datetime.datetime.utcnow() + datetime.timedelta(hours=8) -current_time = now.strftime("%m-%d %H:%M") +current_time = now.strftime("%Y-%m-%d %H:%M") # 打开文本文件并将时间添加到开头 file_path = "酒店优选.txt" with open(file_path, 'r+', encoding='utf-8') as f: content = f.read() f.seek(0, 0) - f.write(f'更新时间,#genre#\n') - f.write(f'请您欣赏,https://vd2.bdstatic.com/mda-mi1dd05gmhwejdwn/sc/cae_h264/1630576203346678103/mda-mi1dd05gmhwejdwn.mp4\n') - f.write(f'{current_time},#genre#\n') + f.write(f'#鉴于酒店源的不实用性,本次最后一次更新。如果需要的话,请fork以后自行启用工作流程\n') + f.write(f'最后更新时间{current_time},#genre#\n') f.write(f'虚情的爱,https://vd2.bdstatic.com/mda-mi1dd05gmhwejdwn/sc/cae_h264/1630576203346678103/mda-mi1dd05gmhwejdwn.mp4\n{content}')