From 8e526deedf30958c1fc98c8fd6ece9e57e541622 Mon Sep 17 00:00:00 2001 From: frxz751113 <156018267+frxz751113@users.noreply.github.com> Date: Thu, 12 Sep 2024 20:08:33 +0800 Subject: [PATCH] =?UTF-8?q?Update=20=E6=B5=8B=E7=BB=98=E7=AB=99=E9=87=87?= =?UTF-8?q?=E9=9B=86.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- py/测绘站采集.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/py/测绘站采集.py b/py/测绘站采集.py index 16a6d83..1beb4b2 100644 --- a/py/测绘站采集.py +++ b/py/测绘站采集.py @@ -749,6 +749,16 @@ for line in fileinput.input("综合源.txt", inplace=True): #打开临时文 line = line.replace("CCTV4K", "CCTV-4K") print(line, end="") +import datetime + +filenames = ["综合源.txt", "综合源.m3u", "组播优选.txt"] + +now = datetime.datetime.now() +current_date = now.strftime("%d") + +new_filenames = [f"{current_date}_{filename}" for filename in filenames] + +print(new_filenames) ################################################################################################任务结束,删除不必要的过程文件