Coder Social home page Coder Social logo

geeksforgeeks.pdf's Introduction

Geeks for Geeks PDFs

Table of Contents of the Dynamic Programming Book.

Download the PDFs from the releases page.

I started in 2015 from @gnijuohz's repo, but now (in 2018) I've re-written pretty much every part of the process.

Dependencies

  • docopt

    • Basic CLI in scripts
  • requests & requests_cache

    • To download pages and cache the result locally
  • lxml

    • Cleaning of the downloaded pages
  • pandoc & xelatex

    • Convert the cleaned pages to PDF

Running the code

  1. First, find out a "topic url" for what you want to download. Eg:

    • https://www.geeksforgeeks.org/tag/samsung/
    • https://www.geeksforgeeks.org/category/dynamic-programming/
  2. Create a JSON containing links of all posts on that topic

    • python3.6 list_links.py https://www.geeksforgeeks.org/tag/samsung/

    • This JSON can now be edited by hand, to remove some links, re-order them etc.

  3. Now fetch the actual posts

    • python3.6 download_html.py JSON/Samsung.json
  4. Finally, convert the HTML to a PDF using Pandoc

    • python3.6 html_to_pdf.py HTML/Samsung.html

Things will work only if you're really lucky. This project has taught me how fragile my HTML to PDF pipeline really is. There's just too many things that can go wrong.

What could go wrong

  • The PDF engine that pandoc calls may err!
    • In which case, you should convert the html to tex
    • Then run pandoc on the tex file in verbose mode
    • and manually fix the tex file

Topic URLs

List of Topic URLs that have I've fetched. You can download these from the releases page.

Algorithms

Data Strucutres

Companies

geeksforgeeks.pdf's People

Contributors

ameenkhan07 avatar dependabot[bot] avatar dufferzafar avatar hdamron17 avatar

Stargazers

 avatar

Forkers

darkhorse-2000

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.