|Lukas Fülling cdc2ff7afc initial||7 months ago|
|.gitignore||7 months ago|
|README.md||7 months ago|
|config-sample.json||7 months ago|
|main.py||7 months ago|
|requirements.txt||7 months ago|
Mastodon bot that posts random images from a folder.
memesdirectory inside this folder and put your images into it
pip install -r requirements.txtto install dependencies
python ./main.pyonce to generate credentials
python ./main.pyagain (when successfully registered) to post
Since the path to the
memes directory is relative, you need to be inside the folder of this
README.md for the bot to work.
Here is a list of the most important configuration options:
||Sets the content warning of the post,
||Decides whether or not the media should be marked as sensitive|
||The Mastodon instance of the Bot|
||Path to the directory where random files to post will be chosen from|
||Number of retries when a randomly selected file was already posted|
Since posting only consists of running
main.py with a valid (registered) config, there are multiple ways of scheduling posts.
Before doing scheduling make sure to generate the client credentials by running
main.py once in an interactive terminal.
The simplest way to do this is running
crontab -e as the user the bot should run as and adding a line like:
*/30 * * * * cd /path/to/memedump/ && /path/to/python main.py
This would result in one post every 30 minutes.