PriceForecast/aa.py
2024-11-01 16:38:21 +08:00

10 lines
339 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 定时执行cmd命令
import os
import time
while True:
print(time.strftime('%H:%M'))
# 判断是不是工作日且 是1700 700 才执行
if time.strftime('%A') not in ['Saturday', 'Sunday'] and time.strftime('%H:%M') in [ '07:00']:
os.system(' D:/ProgramData/anaconda3/python.exe main.py')
time.sleep(60)