🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more

article-crawler

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

article-crawler

A package for crawling markdown formatted articles from certain webpage and storing them locally.

0.0.4
96

Supply Chain Security

100

Vulnerability

98

Quality

100

Maintenance

100

License

Unpopular package

Quality

This package is not very popular.

Found 1 instance in 1 package

Network access

Supply chain risk

This module accesses the network.

Found 1 instance in 1 package

Maintainers
1

Article Crawler

PyPI Latest Release PyPI Downloads

English Doc | 中文文档

✨ Introduction

Article Crawler is a package used to crawl articles with Markdown format from a specific webpage and store them locally in HTML / Markdown formats.

🚀 Quick Start

  • Install through pip

    pip install article-crawler
    
  • Usage

    Usage: python3 -m article_crawler -u [url] -t [type] -o [output_folder] -c [class_] -i [id]

    Options:
      --version             show program's version number and exit
      -h, --help            show this help message and exit
      -u URL, --url=URL     crawled url (required)
      -t TYPE, --type=TYPE  crawled article type [csdn] | [juejin] | [zhihu] | [jianshu]
      -o OUTPUT_FOLDER, --output_folder=OUTPUT_FOLDER
                            output html / markdown / pdf folder (required)
      -w WEBSITE_TAG, --website_tag=WEBSITE_TAG
                            position of the article content in HTML (not required if 'type' is specified)
      -c CLASS_, --class=CLASS_
                            position of the article content in HTML (not required if 'type' is specified)
      -i ID, --id=ID        position of the article content in HTML (not required if 'type' is specified)
    
    • type: Specific websites, currently supported are CSDN, Zhihu, Juejin, and Jianshu.

    • website_tag / class_ / id:

      e.g. <div id="article_content" class="article_content clearfix"></div>

      • In this element, website_tag, class_, id is div, article_content clearfix, article_content respectively.

      • You don't need to specify type when you specify website_tag / class_ / id.
      • You need to use the web console to locate the position of the article.
      • website_tag / class_ / id is used to locate the position of the article in HTML. It is possible to only use one or two of them instead of all.

Open Source License

MIT License see https://opensource.org/license/mit/

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts