Skip to main content

Archive a reddit user's post history. Formatted overview of a profile, JSON containing every post, and picture downloads.

Project description

redditsfinder

pip3 install redditsfinder
A command line program to easily download reddit users' post histories.
Get any reddit user's entire post history with one command while avoiding the reddit API's 1000 post limit.
The main meat of this program is making the requests to pushshift and manipulating pushshift's JSON for a more readable all_posts.json file.
There is also a handly image downloader I made that avoids a lot of the problems of trying to grab multiple images from different sites at once. Things like file types being not what the file is encoded as, and changed URLs. Or a URL that ends with .png that returns ASCII text. It gets imgur albums along with images, because at least for a while imgur was essentially reddit's non-official image hosting service.

The colored terminal features and markup are from https://github.com/willmcgugan/rich
pip3 install rich which is one the coolest python packages I've seen. It's very easy to pick up, but as is shown with the animated example in its README, still has a lot of depth.

https://github.com/LoLei/redditcleaner pip3 install redditcleaner was also a massive help for dealing with reddit's strange markup.
Comments and self-posts can be unreadable when put in another format like JSON if they have a fair amount of formatting.
To deal with it, I gave up and looked online for an alternative. Luckily there was a good one readily available.

Installation and a sample run

With pypi (easiest) pip3 install redditsfinder

With git

pip3 install redditcleaner rich
git clone https://github.com/Fitzy1293/redditsfinder.git
cd redditsfinder

Now test if it works.

python3 redditsfinder.py 'yourUsername'

That's all there is to setup.

Running redditsfinder

Arguments
redditsfinder 'username' returns every user post.
redditsfinder -pics 'username' returns URLs of user's image uploads.
redditsfinder -pics -d 'username' downloads them.

Imgur Image

If you installed with pip

redditsfinder [options] 'username'

If you installed with git

In the directory where you installed redditsfinder.py
python3 redditsfinder.py [options] 'username'

If you made it executable
./redditsfinder.py [options] 'username'

Example JSON object

Imgur Image

Example use of -pics -d

Imgur Image

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Redditsfinder-1.0.9.tar.gz (8.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Redditsfinder-1.0.9-py3-none-any.whl (8.6 kB view details)

Uploaded Python 3

File details

Details for the file Redditsfinder-1.0.9.tar.gz.

File metadata

  • Download URL: Redditsfinder-1.0.9.tar.gz
  • Upload date:
  • Size: 8.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.0.10 CPython/3.8.2 Linux/5.4.0-47-generic

File hashes

Hashes for Redditsfinder-1.0.9.tar.gz
Algorithm Hash digest
SHA256 159c1ea4939d91aac39ae707c12fea8a68aaae5307a5bedf5844de4082e96ca9
MD5 26959f27c8a702dd5b3e0beec8a5742e
BLAKE2b-256 0a0f0d284262e8d069c0224d0666bf41f47b289f7ca8ae8e3ff0eb0b34162f07

See more details on using hashes here.

File details

Details for the file Redditsfinder-1.0.9-py3-none-any.whl.

File metadata

  • Download URL: Redditsfinder-1.0.9-py3-none-any.whl
  • Upload date:
  • Size: 8.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.0.10 CPython/3.8.2 Linux/5.4.0-47-generic

File hashes

Hashes for Redditsfinder-1.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 bdade93f3cdaa29ba0ed071f0144d208b2602731192f19212db3b5004f5ca065
MD5 5748bb6691821ccf13346e714c752cfe
BLAKE2b-256 b4d1d5043722d8abb918d7eda7adc9194e97b329eecf7500290bd036c38d015d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page