Update Gmeek.py
This commit is contained in:
parent
764f495ca6
commit
772f4960f5
8
Gmeek.py
8
Gmeek.py
@ -293,7 +293,7 @@ options = parser.parse_args()
|
|||||||
|
|
||||||
blog=GMEEK(options)
|
blog=GMEEK(options)
|
||||||
|
|
||||||
if not os.path.exists(blog.root_dir+"blogBase.json"):
|
if not os.path.exists("blogBase.json"):
|
||||||
print("blogBase is not exists, runAll")
|
print("blogBase is not exists, runAll")
|
||||||
blog.runAll()
|
blog.runAll()
|
||||||
else:
|
else:
|
||||||
@ -301,13 +301,15 @@ else:
|
|||||||
print("issue_number=='0', runAll")
|
print("issue_number=='0', runAll")
|
||||||
blog.runAll()
|
blog.runAll()
|
||||||
else:
|
else:
|
||||||
f=open(blog.root_dir+"blogBase.json","r")
|
f=open("blogBase.json","r")
|
||||||
print("blogBase is exists and issue_number!=0, runOne")
|
print("blogBase is exists and issue_number!=0, runOne")
|
||||||
blog.blogBase=json.loads(f.read())
|
blog.blogBase=json.loads(f.read())
|
||||||
f.close()
|
f.close()
|
||||||
blog.runOne(options.issue_number)
|
blog.runOne(options.issue_number)
|
||||||
|
|
||||||
listFile=open(blog.root_dir+"blogBase.json","w")
|
listFile=open("blogBase.json","w")
|
||||||
listFile.write(json.dumps(blog.blogBase))
|
listFile.write(json.dumps(blog.blogBase))
|
||||||
listFile.close()
|
listFile.close()
|
||||||
|
shutil.copy("blogBase.json",blog.root_dir)
|
||||||
|
|
||||||
######################################################################################
|
######################################################################################
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user