Install poetry
pip install --user poetry
Create python virtual environment
poetry install
Activate environment
poetry shell
API tokens in tokens.py:
# Imgur API keys
IMGUR_CLIENT_ID = ...
IMGUR_CLIENT_SECRET = ...
# Reddit API keys
REDDIT_CLIENT_SECRET = ...
REDDIT_CLIENT_ID = ...
# Gfycat API keys
GFYCAT_CLIENT_ID = ...
GFYCAT_CLIENT_SECRET = ...
Subreddit specific tokens in dota2.py:
# Twitter API keys
TWITTER_ACCESS_TOKEN = ...
TWITTER_ACCESS_TOKEN_SECRET = ...
TWITTER_CONSUMER_KEY = ...
TWITTER_CONSUMER_SECRET = ...
# Place the subreddit you want to look up posts from here
SUBREDDIT = 'dota2'
HASHTAG = '#dota2'
python reddit_twitter_bot.py dota2