Giter Club home page Giter Club logo

bigen's Introduction

Description

Batch download books from libgen

The idea of this paste is to help optimize the download from Library Genesis and automate the download as simply as possible using a file containing list of links

A normal link from Libgen looks like this
http://gen.lib.rus.ec/book/index.php?md5=3acf98e7e0f54c50f0e4e08d017dc320&open=0

The download link for such link is
http://gen.lib.rus.ec/get?md5=3acf98e7e0f54c50f0e4e08d017dc320&open=0

Now we can easily make a list of download links and save them in a file then input them in wget
wget -i list

But still the problem would be that each file would be saved with a weird name To solve this problem we have to create a file of list of output filenames from the source link then assign for each file its respective filename

Using sed and wget -qO- we can get the title for each link from the source and save the output
wget -qO- -i list.urls | sed -n -e 's!.Genesis: (.)</title>.*!\1!p' > list.names

Now we should create the list of download links from normal links
sed 's:book/index.php:get:g' list.urls > list.downloads

Now that everything seems cool we execute the script
while read durl name; do wget -c "$durl" -O "$name"; done < <(paste list.downloads list.names)

bigen's People

Contributors

x-mel avatar

Stargazers

Dhanush R avatar NightStarr avatar Lyu Ji avatar  avatar  avatar Pronay Ghosh avatar Yorguin José Mantilla Ramos avatar Dimitrij Pinneker avatar Hamish Delap avatar  avatar RoCry avatar  avatar  avatar  avatar

Watchers

James Cloos avatar  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.