上传视频到liveleak.com

pyliveleak的Python项目详细描述


PyliveLeak

https://img.shields.io/pypi/v/pyliveleak.svghttps://img.shields.io/travis/mpenkov/pyliveleak.svgDocumentation StatusUpdates

将视频上载到liveleak.com

功能

示例用法:

$ pyliveleak --path tests/test-data/foreman_cif.mp4 --username "$username" --password "$password"
https://www.liveleak.com/view?i=7ed_1502358506

其他选项:

$ pyliveleak --help
Usage: pyliveleak [OPTIONS]

  Console script for pyliveleak.

Options:
  --loglevel INTEGER
  --password TEXT     Your liveleak.com password  [required]
  --username TEXT     Your liveleak.com username  [required]
  --path PATH         The video to upload  [required]
  --help              Show this message and exit.

您也可以将pyliveleak用作python库:

>>> import pyliveleak
>>> index_page = pyliveleak.login(username, password)
>>> file_token, item_token = index_page.add_item('tests/test-data/foreman_cif.mp4')
>>> item_token
u'b86_1502357642'

您的新视频将在这里提供:https://www.liveleak.com/view?i={item_token}

您可以指定可选元数据:

>>> index_page.add_item('tests/test-data/foreman_cif.mp4', title='my title',
...                     body='detailed description', tags='tags', category='World News')

类别必须是:

>>> pprint.pprint(sorted(pyliveleak.CATEGORIES))
['afghanistan',
 'citizen journalism',
 'conspiracy',
 'creative',
 'history',
 'hobbies',
 'iran',
 'iraq',
 'liveleak challenges',
 'liveleaks',
 'music',
 'nature',
 'other',
 'other entertainment',
 'other items from liveleakers',
 'other middle east',
 'other news',
 'politics',
 'propaganda',
 'regional news',
 'religion',
 'science and technology',
 'sports',
 'syria',
 'ukraine',
 'vehicles',
 'weapons',
 'world news',
 'wtf',
 'yawn',
 'your say']

学分

这个包是用Cookiecutteraudreyr/cookiecutter-pypackage项目模板创建的。

历史记录

0.1.2(2017-08-11)

已修复
  • 在包数据中包含categories.yml(和version),这次是实时的。

0.1.1(2017-08-10)

已添加

  • 更多Sphinx文档

已修复

  • 在包数据中包含categories.yml。
  • 更新sphinx版本,以便正确构建文档。

0.1.0(2017-08-10)

  • pypi上的第一个版本。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
javascript节点js require()和Rhino Shell load()之间的区别是什么?   While循环中的java If语句   java GXT如何在XTemplate中显示treeobject?   如何将黑白图像加载到二进制文件中?   java ORMLite不知道如何存储班级航班。扫描仪。modelFX。机场航空公司的AirlineFx。使用另一个类或自定义持久器   java组织。阿帕奇。德比。客户是SqlException JSP和JSTL查询   spring如何将clob数据分配给java变量   java从上的表获取数据(Spring)   javaphp使用Exec执行带有用户定义参数的Jar文件   java jsonschema2pojo:引用相同类型的对象   使用原语从Scala调用Java vararg方法   java ClassNotFoundException:ClientBuilder Jersey 2.25.1 Tomcat 9.0   Android(Java)cr_BindingManager:无法调用determinedVisibility()从未看到pid的连接:   Java使用LocalTime类比较没有日期的时间   Java如何初始化对象的参数?