A Reddit bot that collects mentions to Portugal throughout Reddit and repost them to r/PortugalOnReddit.
You can easily configure the bot to create a similar subreddit for your country.
- Download the code
- Edit the appropriate variables in config.py
- Pass your Reddit app credentials and account logging to the authenticate function. You can do this by creating a praw.ini file in the same directory of bot.py with the following format:
[OnReddit]
client_id=YOUR_CLIENT_ID
client_secret=YOUR_CLIENT_SECRET
password=YOUR_REDDIT_ACCOUNT_PASSWORD
username=YOUR_REDDIT_ACCOUNT_USERNAME
- Run bot:
python bot.py
A few usefull tools are available to help manage your new subreddit. They are:
start_subreddit
allows you to set up your new subreddit with up to 100 submissions to get things started. It uses Reddit search function to get posts with a minimum score of REQUIRED_SCORE
as defined in config.py.
delete_posts
removes all submissions. If anything goes wrong you can clean up your new subreddit.
stats
gives a few stats
For example, to get your subreddit stats do this:
python tools.py stats