fedifeeds/README.md
2024-11-25 01:48:16 +10:00

58 lines
No EOL
1.2 KiB
Markdown

# fedifeeds
RSS feeds to Mastodon API. Supports multiple feeds per account, Markdown, and automatic threading (split into multiple notes to fit character limit).
## Setup
Make sure you have:
- Python 3.10+
- python-virtualenv
- pip3
Clone and install dependencies
```commandline
git clone https://codeberg.org/pancakes/fedifeeds.git
cd fedifeeds
python3 -m virtualenv .venv
.venv/bin/pip3 install -r requirements.txt
```
### Login
Use the login script
```commandline
.venv/bin/python3 login.py
```
### Configuration
Create a JSON file with
- Keys being the URL to the RSS feed
- Values being the unix timestamp that is used as the minimum entry date
Example:
```json
{
"https://example.org/feed1.rss": 0,
"https://example.org/feed2.rss": 0
}
```
## Running
When running it will ignore every entry older than the configured timestamp and post the rest to the selected account. After running the feed config is automatically updated with the timestamp of the latest entry to avoid duplication.
```commandline
.venv/bin/python3 main.py <username> <config>
```
Cron example (every 30 minutes):
```crontab
*/30 * * * * (cd <fedifeeds-path>; .venv/bin/python3 main.py <username> <config>
```