主机参考:VPS测评参考推荐/专注分享VPS服务器优惠信息!若您是商家可以在本站进行投稿,查看详情!此外我们还提供软文收录、PayPal代付、广告赞助等服务,查看详情! |
我们发布的部分优惠活动文章可能存在时效性,购买时建议在本站搜索商家名称可查看相关文章充分了解该商家!若非中文页面可使用Edge浏览器同步翻译!PayPal代付/收录合作 |
使用前请先安装 Python3
- import re
- import sys
- import os,glob
- # 定义目录:目录下有多个文件需要处理,为 accounts 目录的路径,例如: path = ‘D://AutoRclone//accounts’
- path = ‘path//to//your//accounts’
- # 定义输出文件,路径可自定义,例如 fout = open(“D://AutoRclone//accounts//res.txt”, ‘w’)
- fout = open(“res.txt”, ‘w’)
- os.chdir(path)
- fout.write(“用户名和邮箱(便于查询)n”)
- for filename in os.listdir() :
- fs = open(filename, ‘r+’)
- fout.write(“文件名:” + filename + ‘n’)
- for line in fs.readlines():
- mylist_1 = line.split(“:”)
- if mylist_1[0] == ” “client_email”” :
- mylist_2 = mylist_1[1].split(“””)
- fout.write(mylist_2[1] + ‘n’)
- fout.write(“nn”)
- fout.write(“邮箱(便于添加到 Google group)n”)
- for filename in os.listdir() :
- fs = open(filename, ‘r+’)
- for line in fs.readlines():
- mylist_1 = line.split(“:”)
- if mylist_1[0] == ” “client_email”” :
- mylist_2 = mylist_1[1].split(“””)
- fout.write(mylist_2[1] + ‘n’)
- fout.write(‘n’)
- fout.close()
项目地址:https://github.com/Sheldonsix/A-python-scr教程:https://blog.csdn.net/lavorange/article/details/41647091
这几篇文章你可能也喜欢:
- Hengchuang Technology 618折扣:整个服务器的低点可享受25%的折扣,提供高防御IP,老年用户从30%的折扣中获得更新。
- Hengchuang技术:双重11、13元云服务器的最低价格,大带宽云239元,裸机500 yuan
- http状态500错误是什么意思?
- 亚洲云:双十一大优惠,高端高带宽云服务器40折,免费双倍流量和硬盘
- 如何解决http状态404?
本文由主机参考刊发,转载请注明:用 Python 写了一个搭配 AutoRclone 和 gclone 的小脚本 https://zhujicankao.com/16813.html
评论前必须登录!
注册