Giter Club home page Giter Club logo

fancaps-scraper's Introduction

FanCaps-Scrapper

A Node.js async CLI scrapper for anime screenshots on https://fancaps.net. README template from https://www.makeareadme.com/

Installation

git clone https://github.com/Fannovel16/fancaps-scraper
cd fancaps-scraper
npm install
cd ..

Usage

CLI syntax

node fancaps-scraper [-h] [-v] \ 
    --seriesUrl SERIESURL \
    [--saveDir SAVEDIR] \
    [--numOfPromises NUMOFPROMISES] \
    [--forceUnlimitedPromises] \
    [--skipNLastPages SKIPNLASTPAGES] \
    [--writeMetadata] \
    [--readMetadata] \
    [--dontDownloadImages] \

Arguments:

  • -h, --help: show this help message and exit
  • -v, --version: show program's version number and exit
  • --url URL: The url of the series or movie you want to download images from, not the episode url.
    Any kind of url that starts with https://fancaps.net/movies/MovieImages.php or https://fancaps.net/anime/showimages.php will be accepted e.g.: ** https://fancaps.net/anime/showimages.php?33224-Bocchi_the_Rock ** https://fancaps.net/movies/MovieImages.php?name=Fate_Stay_Night_Heaven_s_Feel_I_Presage_Flower_2017&movieid=2666 ** https://fancaps.net/movies/MovieImages.php?movieid=2666
  • --saveDir SAVEDIR: The location to save images, the default value is ./fancaps-images/title of series
    (e.g. ./fancaps-images/Bocchi The Rock)
  • --numOfPromises NUMOFPROMISES: The number of promises to use (imagine it is similar to multi-threading).
    A error will be thrown if it > 75 due to Cloudflare CDN's hidden rate limit unless --forceUnlimitedPromises is passed
  • --forceUnlimitedPromises
  • --skipNLastPages SKIPNLASTPAGES: Skip n last pages so most of credit frames won't be downloaded
  • --writeMetadata: Write episodeDataset to metadata.json
  • --readMetadata: Read episodeDataset from metadata.json
  • --dontDownloadImages
  • --colab: Add line break to the progress bar if the env is Colab
  • --disableProgressBar

Result folder architecture

Episode

$saveDir
├── Episode 1
│   ├── intId.jpg
│   ├── anotherIntId.jpg
│   ├── ...
├── Episode 2
│   ├── intId.jpg
│   ├── anotherIntId.jpg
│   ├── ...
├── Episode ...

For example:

node fancaps-scraper --seriesUrl="https://fancaps.net/anime/showimages.php?33224-Bocchi_the_Rock"

Should give the following result:

./fancaps-images/Bocchi the Rock!
├───Episode 1
│   ├── 22361835.jpg
│   ├── 22361837.jpg
│   ├── 22361838.jpg
│   ├── ...
│   ├── 22362709.jpg
├───Episode 2
│   ├──22363017.jpg
│   ├──22363020.jpg
│   ├──22363022.jpg
│   ├── ...
│   ├── ...
│   ├── 22364001.jpg
├───Episode 3
├───Episode 4
├───Episode 5
├───Episode 6
├───Episode 7
├───Episode 8
├───Episode 9
├───Episode 10
├───Episode 11
└───Episode 12

Movie

$saveDir
├── intId.jpg
├── anotherIntId.jpg
├── ...

Contributing

I'm an ameatur programmer so when you make a pull request, plz explain it at a way that is easy to understand. Also I'm needing someone to refactor my code.

License

MIT

fancaps-scraper's People

Contributors

fannovel16 avatar reenmikki avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.