跳转到主要内容

Gabber是一个用于抓取和分析Gab帖子的小工具。

项目描述

Gabber

从Gab拉取帖子和使用者的简单工具。

使用方法

Usage: gabber [OPTIONS] COMMAND [ARGS]...

Options:
  --user TEXT        Username to gab.com account. Required to pull posts. If
                     unspecified, uses GAB_USER environment variable.
  --password TEXT    Password to gab.com account. Required to pull posts. If
                     unspecified, uses GAB_PASS environment variable.
  --threads INTEGER  Number of threads to use in the pull (if unspecified,
                     defaults to 25).
  --help             Show this message and exit.

Commands:
  groups  Pull groups and (optionally) their posts from Gab.
  users   Pull users and (optionally) posts from Gab.

users

Usage: gabber users [OPTIONS]

  Pull users and (optionally) posts from Gab.

Options:
  --users-file TEXT              Where to output the user file to.
  --posts-file TEXT              Where to output the posts file to.
  --first INTEGER                The first user ID to pull.
  --last INTEGER                 The last user ID to pull.
  --created-after FROMISOFORMAT  Only pull posts created on or after the
                                 specified date, e.g. 2021-10-02 (defaults to
                                 none).
  --posts / --no-posts           Pull posts (WIP; defaults to no posts).
  --replies / --no-replies       Include replies when pulling posts (defaults
                                 to no replies)
  --help                         Show this message and exit.

groups

Usage: gabber groups [OPTIONS]

  Pull groups and (optionally) their posts from Gab. Can pull at most 250
  pages of posts per group (5000 posts).

Options:
  --groups-file TEXT    Where to output the groups file to.
  --posts-file TEXT     Where to output the posts file to.
  --first INTEGER       The first group ID to pull.
  --last INTEGER        The last group ID to pull.
  --depth INTEGER       How many pages of posts to retrieve.
  --posts / --no-posts  Pull posts.
  --help                Show this message and exit.

followersfollowing

Usage: gabber [followers|following] [OPTIONS]

  Experimental feature: pull followers from a Gab account / pull list of accounts that a Gab account follows.

Options:
  --id INTEGER                User id from which to pull followers.
  --[followers|following]-file-path TEXT  Where to output the followers file to
  --help                      Show this message and exit.

环境变量

  • HTTPS_PROXY — 通过此HTTPS代理路由所有流量(考虑到Gab的限制,强烈推荐)

    • 注意:如果您有现有的 HTTP_PROXY 环境变量,Python的requests库可能会将其拾取并产生错误。
  • GAB_USER — (可选) 使用Gab进行身份验证的(可选)用户名

  • GAB_PASS — (可选) 使用Gab进行身份验证时使用的(可选)密码

开发

要在开发环境中运行Gabber,您需要 Poetry。通过运行 poetry install 安装依赖项,然后您就可以在本地对Gabber进行工作了。

要访问CLI,请运行 poetry run gabber

项目详情


下载文件

下载适用于您的平台的文件。如果您不确定选择哪个,请了解更多关于 安装包 的信息。

源代码分发

gabber-0.1.2.tar.gz (14.9 kB 查看哈希值)

上传时间 源代码

构建分发

gabber-0.1.2-py3-none-any.whl (15.2 kB 查看哈希值)

上传时间: Python 3

由以下支持