Publish in your tumblr blog the poster of the movie that you want.
This script needs the API of Tumblr and TMDB.
- How to get those APIs
- TMBD: Create an account and follow this easy steps.
- Tumblr: Follow this steps.
interactive_console.py
will create a.tumblr
file in your root path.
Clone this repo and install it wherever you want.
git clone https://github.com/lud0matic/imdb-to-tumblr.git
Rename .env.exam
to .env
Copy every API KEY that you get from the Prerequisites and paste it in .env
file. In BLOG_NAME=
write the name of your blog without tumblr.com
.
If you use poetry
, run.
poetry install
Otherwise, use pip
.
pip install -r requirements.txt
Poetry
doesn't load .env
variables by default. I installed this plugin to solve this.
If you end up using pip
, install python-dotenv
pip install python-dotenv
And uncomment this two lines in main.py file.
from dotenv import load_dotenv
load_dotenv()
Find in imdb.com the movie poster that you want to puslish and copy the imdb id. In this case tt6467226
.
Run the script including the id. You will get the movie's name and the post url.
The title of the post will be the name of the movie, and the tags will include the original movie's name, its translation to english, the director's name and the current year. If you use the -f
flag, the favorite tag will be included in the post. This helps to filter all the posts that you think deserve that category.
Since 2011, I have been posting the poster of every movie I watched. It is one of the many things I love to keep track of. During the pandemic, I learned Python. Before that, every post I published on my blog was created manually. I would search for the poster, resize it, copy the movie's name and director, and then publish the post. At one point, I ended up hating this process. The main idea behind this script is to automate the entire process.
I added a progress bar while the script is running. It shows the percentage, the amount of steps completed, the time elapsed and the estimated time remaining. Thanks @jsagredo-scott for the idea :))