Skip to content

clamytoe/animpy

Repository files navigation

Anime Python Research Tool (animpy)

Just a little tool to make it easier for me to look up anime reviews.

Python version Latest version Build Status BCH compliance GitHub issues GitHub forks GitHub Stars License

My kids are big movie and anime buffs and are constantly asking me to look up shows to see if they are allowed to watch them. This of course takes time, more so when they bring you a list of them!

I initially wrote Parental Guide (pguide) but IMDb isn't really the greatest place to find reviews for anime. That lead me to start from scratch, so I created this one that scrapes MyAnimeList instead.

Requirements

  1. Requires Python 3.6+
  2. Requires all the packages you need in order to install animpy into your preferred flavor of virtual environment (of the three mentioned in the steps below that is).

How To Set It All Up

Use a virtual environment. A requirements.txt and an environment.yml file are included already. Perform the steps in the Initial Setup to clone the repo and then choose whichever set of Setup instructions for the virtual environment you prefer to work with.

Initial Setup: Cloning the Repo

  1. Create and then change into the directory you would like to install animpy into.
    • mkdir <directory name>
    • cd <directory name>
    • git clone https://github.com/clamytoe/animpy.git
    • cd animpy

Anaconda Setup

  1. conda env create (creates the virtual environment)
  2. activate animpy or source activate animpy (activates the virtual environment)
  3. pip install -e . (installs the animpy package)

Regular Python 3 Virtual Environment Setup

  1. python3 -m venv </path/to/new/virtual/environment> (creates the virtual environment)
  2. source </path/to/new/virtual/environment>/bin/activate (activates the virtual environment)
  3. pip install -r requirements.txt (installs all required dependencies)
  4. pip install -e . (installs the animpy package)

How To Use

Once you've installed animpy into your virtual environment, using the script is pretty straight forward. If you use the --help flag it will display the following usage statement:

Usage: animpy [OPTIONS]

  Entry point for the script, requires the title of the Anime to look up.

  If a title is not given from the command line, one will be asked for.
  :param title: String, the title of the show :return: None

Options:
  --show / --no-show   Toggles display search results on/off, defaults to off.
  -c, --count INTEGER  Number of search results to display, default is 5.
  -t, --title TEXT     Title of the Anime that you would like to look up, use
                       double-quotes.
  --help               Show this message and exit.

Method #1

animpy

You will be prompted for the title.

Method #2

animpy -t "D.Grey-man"

# or

animpy --show --count 2 --title "D.Gray-man"

Sample run

Notice that even if there is a type-o in the search term, the correct show is still found.

sample run

search

Just hitting the ENTER key will continue with the next screen. To exit enter an n.

Releases

No releases published

Packages

 
 
 

Languages