add support for Alive.in.th, fix #190

This commit is contained in:
Mort Yao 2013-06-13 00:12:45 +02:00
parent f302540303
commit fc24a267b5
5 changed files with 26 additions and 0 deletions

View File

@ -50,6 +50,7 @@ Fork me on GitHub: <https://github.com/soimort/you-get>
* Baidu Music (百度音乐) <http://music.baidu.com>
* Baidu Wangpan (百度网盘) <http://pan.baidu.com>
* SongTaste <http://www.songtaste.com>
* Alive.in.th <http://alive.in.th>
## Dependencies
@ -267,6 +268,7 @@ You-Get基于优酷下载脚本[iambus/youku-lixian](https://github.com/iambus/y
* 百度音乐 <http://music.baidu.com>
* 百度网盘 <http://pan.baidu.com>
* SongTaste <http://www.songtaste.com>
* Alive.in.th <http://alive.in.th>
## 依赖

View File

@ -53,6 +53,7 @@ Supported Sites (As of Now)
* Baidu Music (百度音乐) http://music.baidu.com
* Baidu Wangpan (百度网盘) http://pan.baidu.com
* SongTaste http://www.songtaste.com
* Alive.in.th http://alive.in.th
Dependencies
------------

View File

@ -33,6 +33,7 @@ def url_to_module(url):
'google': google,
'iask': sina,
'ifeng': ifeng,
'in': alive,
'iqiyi': iqiyi,
'joy': joy,
'jpopsuki': jpopsuki,

View File

@ -1,6 +1,7 @@
#!/usr/bin/env python
from .acfun import *
from .alive import *
from .baidu import *
from .bilibili import *
from .blip import *

View File

@ -0,0 +1,21 @@
#!/usr/bin/env python
__all__ = ['alive_download']
from ..common import *
def alive_download(url, output_dir = '.', merge = True, info_only = False):
html = get_html(url)
title = r1(r'<meta property="og:title" content="([^"]+)"', html)
url = r1(r'file: "(http://alive[^"]+)"', html)
type, ext, size = url_info(url)
print_info(site_info, title, type, size)
if not info_only:
download_urls([url], title, ext, size, output_dir, merge = merge)
site_info = "Alive.in.th"
download = alive_download
download_playlist = playlist_not_supported('alive')