动手下载网易课程视频 -- 正式下载

1. Eclipse中网易公开课课程下载代码

'''
Created on Mar 22, 2019

@author: chwang
'''
import sys
import you_get

def download(url, path):
    sys.argv = ['you-get', '-o', path, url]
    you_get.main()

    
if __name__ == '__main__':
    
    path = r'C:\Users\chwang\Desktop'
    
    url1 = r'http://open.163.com/movie/2010/11/7/3/M6V0BQC4M_M6V29E773.html'
    url2 = r'https://open.163.com/movie/2010/11/P/P/M6V0BQC4M_M6V29EGPP.html'
    
    download(url1, path)
    download(url2, path)

2. 查看下载后的视频

下载过程,如下,
动手下载网易课程视频 -- 正式下载_第1张图片
在路径C:\Users\chwang\Desktop下查看下载后的视频,如下,
动手下载网易课程视频 -- 正式下载_第2张图片

你可能感兴趣的:(Python编程)