V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
shuson
V2EX  ›  Python

如果你们也喜欢落网上按期整理的音乐,并且想下载下来,且又懒得写脚本,请。。。

  •  
  •   shuson · 2016-01-15 17:47:15 +08:00 · 2388 次点击
    这是一个创建于 3034 天前的主题,其中的信息可能已经有所发展或是发生改变。

    python 大法好

    爬网页(requests+beautifulsoup) -> 建文件 and 夹(os) -> 下载(requests)

    我只是 lib 的搬运工

    欢迎 new pull request
    落网音乐下载小帮手

    6 条回复    2016-01-16 10:41:36 +08:00
    GNiux
        1
    GNiux  
       2016-01-15 17:49:08 +08:00 via iPhone
    不知用 Bash 脚本可否完成这个任务呢?
    xingso
        2
    xingso  
       2016-01-15 17:52:41 +08:00
    管它到。。先 star 慢慢下
    shuson
        3
    shuson  
    OP
       2016-01-15 18:04:22 +08:00
    @GNiux 从理论上来讲,肯定可以,问题是人类进步就靠懒,用 bash 解析 html 可烦人了
    shuson
        4
    shuson  
    OP
       2016-01-15 18:05:01 +08:00
    @xingso 欢迎成为第一个试用者,我没有在无 proxy 环境测试,不知道能不能工作
    GNiux
        5
    GNiux  
       2016-01-15 20:40:07 +08:00 via iPhone
    @shuson 是的呢。所以 systemd 大行其道。
    Bash 的话,用 curl?
    shuson
        6
    shuson  
    OP
       2016-01-16 10:41:36 +08:00   ❤️ 1
    @GNiux 对 curl 可以做到,但是 encoding 是个问题。
    我更新了一下代码,设置了一下 sys default encoding ,还是 python 简单
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   1084 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 18:48 · PVG 02:48 · LAX 11:48 · JFK 14:48
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.