{"id":53402,"date":"2020-04-06T05:38:35","date_gmt":"2020-04-05T21:38:35","guid":{"rendered":"http:\/\/4563.org\/?p=53402"},"modified":"2020-04-06T05:38:35","modified_gmt":"2020-04-05T21:38:35","slug":"%e7%94%a8-python-%e5%86%99%e4%ba%86%e4%b8%80%e4%b8%aa%e6%90%ad%e9%85%8d-autorclone-%e5%92%8c-gclone-%e7%9a%84%e5%b0%8f%e8%84%9a%e6%9c%ac","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=53402","title":{"rendered":"\u7528 Python \u5199\u4e86\u4e00\u4e2a\u642d\u914d AutoRclone \u548c gclone \u7684\u5c0f\u811a\u672c"},"content":{"rendered":"\n<p>  \t\t\t\t\t<strong>Sheldonliu<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3>\u7528 Python \u5199\u4e86\u4e00\u4e2a\u642d\u914d AutoRclone \u548c gclone \u7684\u5c0f\u811a\u672c<\/h3>\n<p>  \t\t\u81ea\u5b66\u4e86 Python \u51e0\u5929\uff0c\u4e00\u76f4\u60f3\u4eb2\u81ea\u52a8\u624b\u5b9e\u8df5\u4e00\u756a\uff0c\u4e8e\u662f\u5199\u4e86\u4e00\u4e2a\u4e0e\u5b57\u7b26\u4e32\u63d0\u53d6\u6709\u5173\u7684\u5c0f\u811a\u672c\uff0c\u4e0e AutoRclone \u6216 gclone \u642d\u914d\u98df\u7528\uff0c\u63d0\u53d6 accounts \u76ee\u5f55\u4e0b json \u6587\u4ef6\u7684\u6587\u4ef6\u540d\u548c\u90ae\u7bb1\uff0c\u4fbf\u4e8e\u67e5\u8be2\u548c\u6dfb\u52a0\u5230 Google groups<br \/>  \u4f7f\u7528\u524d\u8bf7\u5148\u5b89\u88c5 Python3<\/p>\n<p>  import re<br \/>  import sys<br \/>  import os,glob<\/p>\n<p>  # \u5b9a\u4e49\u76ee\u5f55\uff1a\u76ee\u5f55\u4e0b\u6709\u591a\u4e2a\u6587\u4ef6\u9700\u8981\u5904\u7406\uff0c\u4e3a accounts \u76ee\u5f55\u7684\u8def\u5f84\uff0c\u4f8b\u5982\uff1a path = &#8216;D:\/\/AutoRclone\/\/accounts&#8217;<br \/>  path = &#8216;path\/\/to\/\/your\/\/accounts&#8217;<br \/>  # \u5b9a\u4e49\u8f93\u51fa\u6587\u4ef6\uff0c\u8def\u5f84\u53ef\u81ea\u5b9a\u4e49\uff0c\u4f8b\u5982 fout = open(&quot;D:\/\/AutoRclone\/\/accounts\/\/res.txt&quot;, &#8216;w&#8217;)<br \/>  fout = open(&quot;res.txt&quot;, &#8216;w&#8217;)<\/p>\n<p>  os.chdir(path)<\/p>\n<p>  fout.write(&quot;\u7528\u6237\u540d\u548c\u90ae\u7bb1\uff08\u4fbf\u4e8e\u67e5\u8be2\uff09n&quot;)<br \/>  for filename in os.listdir() :<br \/>  &nbsp; &nbsp; fs = open(filename, &#8216;r+&#8217;)<br \/>  &nbsp; &nbsp; fout.write(&quot;\u6587\u4ef6\u540d\uff1a&quot; + filename + &#8216;n&#8217;)<br \/>  &nbsp; &nbsp; for line in fs.readlines():<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;mylist_1 = line.split(&quot;:&quot;)<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;if mylist_1 == &quot;&quot;client_email&quot;&quot; :<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;mylist_2 = mylist_1.split(&quot;&quot;&quot;)<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;fout.write(mylist_2 + &#8216;n&#8217;)<\/p>\n<p>  fout.write(&quot;nn&quot;)<br \/>  fout.write(&quot;\u90ae\u7bb1\uff08\u4fbf\u4e8e\u6dfb\u52a0\u5230 Google group\uff09n&quot;)<br \/>  for filename in os.listdir() :<br \/>  &nbsp; &nbsp; fs = open(filename, &#8216;r+&#8217;)<br \/>  &nbsp; &nbsp; for line in fs.readlines():<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;mylist_1 = line.split(&quot;:&quot;)<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;if mylist_1 == &quot;&quot;client_email&quot;&quot; :<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;mylist_2 = mylist_1.split(&quot;&quot;&quot;)<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;fout.write(mylist_2 + &#8216;n&#8217;)<br \/>  fout.write(&#8216;n&#8217;)<br \/>  fout.close()<\/p>\n<p>  \u9879\u76ee\u5730\u5740\uff1ahttps:\/\/github.com\/Sheldonsix\/A-python-script-of-AutoRclone-or-gclone<br \/>  \u53c2\u8003\u6559\u7a0b\uff1ahttps:\/\/blog.csdn.net\/lavorange\/article\/details\/41647091\t\t\t\t<\/p>\n<p>  \t\t\t\t\t<strong>yidaomm<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3><\/h3>\n<p>  \t\t\u6b64\u8d34\u5fc5\u706b\uff0c:lol\t\t\t\t<\/p>\n<p>  \t\t\t\t\t<strong>b66667777<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3><\/h3>\n<p>  \t\t\u611f\u8c22\u5206\u4eab\t\t\t\t<\/p>\n<p>  \t\t\t\t\t<strong>hjvn2211445<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3><\/h3>\n<p>  \t\t \u672c\u5e16\u6700\u540e\u7531 hjvn2211445 \u4e8e 2020-4-6 16:54 \u7f16\u8f91 <\/p>\n<p> \u4e5f\u53ef\u4ee5\u63d2\u4ef6\u7f51\u9875\u4e0a\u63d0\u53d6\u90ae\u7bb1\uff0c<br \/>  \u63d2\u4ef6https:\/\/chrome.google.com\/webstore\/detail\/email-extractor\/fgcoaakamhopmbbbllmpocacgkhjhmbp?hl=zh-CN<\/p>\n<p>  \/**<br \/>   * <br \/>  Rclone\u9ad8\u7ea7\u73a9\u6cd5&#8211;\u5229\u7528\u670d\u52a1\u8d26\u53f7\u7a81\u7834\u65e5\u6d41\u91cf750G\u9650\u5236 &#8211; Jialezi `s blog&nbsp; &nbsp; http:\/\/blog.jialezi.net\/?post=153<br \/>   *<br \/>   * *\/\t\t\t\t<\/p>\n<p>  \t\t\t\t\t<strong>Sheldonliu<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3><\/h3>\n<p>  \t\thjvn2211445 \u5927\u4f6c\u6709\u8bdd\u8bf4 : 2020-4-6 12:39<br \/>  \u4e5f\u53ef\u4ee5\u63d2\u4ef6\u7f51\u9875\u4e0a\u63d0\u53d6\u90ae\u7bb1\uff0c<br \/>  \u63d2\u4ef6https:\/\/chrome.google.com\/webstore\/detail\/email-extractor\/fgcoaakamho &#8230;<\/p>\n<p> \u563f\u563f\u611f\u8c22\u5206\u4eab\uff0c\u90a3\u4e2a\u63d2\u4ef6\u66f4\u65b9\u4fbf\uff0c\u4e0d\u8fc7\u63d0\u53d6\u4e0d\u4e86\u6587\u4ef6\u540d\uff0c\u5c31\u4e0d\u6e05\u695a\u54ea\u4e2a\u90ae\u7bb1\u5bf9\u5e94\u54ea\u4e2a\u6587\u4ef6\t\t\t  <\/p>\n","protected":false},"excerpt":{"rendered":"<p>Sheldonliu \u5927\u4f6c\u6709\u8bdd\u8bf4 &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/53402"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=53402"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/53402\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=53402"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=53402"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=53402"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}