프로그래밍언어/Python

파일 다운로드

부산딸랑이 2014. 9. 25. 02:45

def downloadtorrent(url):
    f = urllib.request.urlopen(url)
    with open("t.torrent", "wb") as code:
        code.write(f.read())
    #subprocess.Popen("t.torrent")
    os.system('start ' + 't.torrent')