Andreas Demmelbauer 6ca8782ac0 | 6 年前 | |
---|---|---|
.gitignore | 6 年前 | |
LICENSE | 7 年前 | |
README.md | 6 年前 | |
config-example.json | 6 年前 | |
cron-example.sh | 6 年前 | |
requirements.txt | 6 年前 | |
tootbot.py | 6 年前 |
A small python 3.x script to replicate tweets and posts from soup.io on a mastodon account. It’s based on TootBot: https://github.com/cquest/tootbot
The script only need mastodon login/pass to post toots.
For Twitter, it gets the tweets from RSS available at http://twitrss.me, then does some cleanup on the content:
For Soup, it uses the official RSS feed (e.g. https://metalab.soup.io/rss), then does some cleanup on the content:
A sqlite database is used to keep track of items than have been tooted.
This script ist used by metalab: https://chaos.social/@metalab
You may want to run it in a virtualenv:
virtualenv -p python3 ~/.virtualenvs/tootbot-spicy
source ~/.virtualenvs/tootbot-spicy/bin/activate
(tootbot)
in the prompt is indicating which virtualenv you are currently using.cd tootbot-spicy
pip3 install -r requirements.txt
cp config-example.json config.json
.config.json
cp cron-example.sh cron.sh
.cron.sh
cron.sh
: crontab -e
deactivate
The script is simply called by a cron job and can run on any server (does not have to be on the mastodon instance server).