SIGN IN SIGN UP
injetlee / Python UNCLAIMED

Python脚本。模拟登录知乎, 爬虫,操作excel,微信公众号,远程开机

0 0 0 Python
2016-06-23 23:27:21 +08:00
import os
dir = os.getcwd()
subdir = os.listdir(dir)
for i in subdir:
2016-12-09 14:22:52 +08:00
path = os.path.join(dir, i)
if os.path.isdir(path):
end_dir = os.listdir(path)
for i in range(len(end_dir)):
newname = end_dir[i][0:50]
os.rename(os.path.join(path, end_dir[
i]), os.path.join(path, newname))