项目作者: KevCui

项目描述 :
🎥 A script to show TMDB movie/TV series information in terminal
高级语言: Python
项目地址: git://github.com/KevCui/tmdb-movie-informer.git
创建时间: 2016-12-26T21:24:48Z
项目社区:https://github.com/KevCui/tmdb-movie-informer

开源协议:Do What The F*ck You Want To Public License

下载



Title: tmdb-movie-informer
Description: look up movie/TV series information from TMDb
Author: KrazyCavin
Tags: CLI, python, script

created: 26 Dec 2016

tmdb-movie-informer

Show movie or TV series information, using API from TMDB. It’s really fast but it needs to register an API KEY first. Then put API KEY inside config.ini file

What kind of information this script will display?

  • Title: movie/TV series title
  • Date: release date(day, month and year)
  • Genre
  • Length: run time(min)
  • Rating: ratings from TMDB and IMDB
  • Links: links to TMDB and IMDB if available

Requirement

  • Python3
  • beautifulsoup4
  • texttable
  • requests

Install python package

  • pip install -r requirements.txt

How to use

  1. usage: tmdb [-h] [-y [YEAR]] [-t] [-d] searchtext [searchtext ...]
  2. positional arguments:
  3. searchtext search text
  4. optional arguments:
  5. -h, --help show this help message and exit
  6. -y [YEAR], --year [YEAR]
  7. year of release
  8. -t, --tv search TV show
  9. -d, --debug active debug log

:warning: With -d, a debug log file tmdb.log will be created in script-run-directory.

Example

  • List new star wars movie Rogue One
    ```bash
    ~ $ ./tmdb rogue one -y 2016
    Find 2 results

+————————-+——————+——————+——————+————————-+—————————————————————+
| TITLE | DATE | GENRE | LENGTH | RATING | LINK |
+=================+============+============+============+=================+==========================================+
| Rogue One: A | 2016-12-14 | Action, | 134 | TMDB: 7.4(848) | https://www.themoviedb.org/movie/330459 |
| Star Wars Story | | Adventure, | | IMDB:8.2 | http://www.imdb.com/title/tt3748528 |
| | | Sci-Fi | | (143,977) | |
+————————-+——————+——————+——————+————————-+—————————————————————+
| The Rogue One: | 2016-12-15 | Animation, | 3 | TMDB: 0.0(0) | https://www.themoviedb.org/movie/431575 |
| A Star Wars Toy | | Short, | | | http://www.imdb.com/title/tt6343680 |
| Story | | Comedy | | | |
+————————-+——————+——————+——————+————————-+—————————————————————+

  1. * List **Game of Thrones** information
  2. ```bash
  3. ~ $ ./tmdb game of thrones -t
  4. Find 1 result
  5. +-----------------+------------+------------+------------+-----------------+------------------------------------------+
  6. | TITLE | DATE | GENRE | LENGTH | RATING | LINK |
  7. +=================+============+============+============+=================+==========================================+
  8. | Game of Thrones | 2011-04-17 | Sci-Fi & | [60] | TMDB: 7.8(1420) | https://www.themoviedb.org/tv/1399 |
  9. | | | Fantasy, | | | |
  10. | | | Action & | | | |
  11. | | | Adventure, | | | |
  12. | | | Drama | | | |
  13. +-----------------+------------+------------+------------+-----------------+------------------------------------------+
  • List episodes of Season 3 in Black Mirror
    ```bash
    ~ $ ./tmdb black mirror -s 3
    Find 6 results

+————————-+——————+——————+——————+————————-+—————————————————————+
| TITLE | DATE | GENRE | LENGTH | RATING | LINK |
+=================+============+============+============+=================+==========================================+
| S3E1 Nosedive | 2016-10-21 | | | TMDB: 7.667(3) | |
+————————-+——————+——————+——————+————————-+—————————————————————+
| S3E2 Playtest | 2016-10-21 | | | TMDB: 7.333(3) | |
+————————-+——————+——————+——————+————————-+—————————————————————+
| S3E3 Shut Up | 2016-10-21 | | | TMDB: 9.0(3) | |
| and Dance | | | | | |
+————————-+——————+——————+——————+————————-+—————————————————————+
| S3E4 San | 2016-10-21 | | | TMDB: 8.0(4) | |
| Junipero | | | | | |
+————————-+——————+——————+——————+————————-+—————————————————————+
| S3E5 Men | 2016-10-21 | | | TMDB: 7.5(2) | |
| Against Fire | | | | | |
+————————-+——————+——————+——————+————————-+—————————————————————+
| S3E6 Hated in | 2016-10-21 | | | TMDB: 9.0(2) | |
| the Nation | | | | | |
+————————-+——————+——————+——————+————————-+—————————————————————+

```