Commit 24b77ddc authored by 张彦钊's avatar 张彦钊

add print

parent c83146c8
import os
import time
def check():
out = os.popen("ps aux | grep diaryQueueUpdate.py").read()
flag = 1
for line in out.splitlines():
if 'python diaryQueueUpdate.py' in line:
flag = 2
return flag
if __name__ == "__main__":
while True:
print(2)
if check() == 1:
os.popen('python diaryQueueUpdate.py')
print("成功启动diaryQueueUpdate")
time.sleep(300)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment