Another RSS to Mastodon bot.
Go to file
2018-03-11 15:40:25 +01:00
src started to refactor a bit 2018-03-11 15:40:25 +01:00
.gitignore initial commit 2018-01-26 02:33:58 +01:00
CMakeLists.txt started to refactor a bit 2018-03-11 15:40:25 +01:00
LICENSE initial commit 2018-01-26 02:33:58 +01:00
README.md docfix 2018-02-28 22:51:25 +01:00
watchwords.json more filtering 2018-02-01 12:03:16 +01:00

mastorss dumps RSS feeds into a mastodon account. It is hacked together and generally only extended/fixed when it fails. Do NOT assume it follows any standards. Use at your own risk.

Install

Dependencies

  • Tested OS: Linux
  • C++ compiler (tested: gcc 6.4, clang 5.0)
  • cmake (tested: 3.9.6)
  • boost (tested: 1.63.0)
  • libcurl (tested: 7.58.0)
  • curlpp (tested: 0.8.1)
  • mastodon-cpp (at least: 0.2.13)

Get sourcecode

Development version

git clone https://github.com/tastytea/mastorss.git

Compile

mkdir build
cd build/
cmake ..
make

cmake options:

  • -DCMAKE_BUILD_TYPE=Debug for a debug build

Install with make install.

Usage

Put watchwords.json into ~/.config/mastorss/. Launch with profile name. The first occurence of every watchword in an RSS item will be turned into a hashtag. For profile-specific watchwords see the example in watchwords.json. In the first run only the newest entry is tooted.

The profile can't be named "global".

Example config file

${HOME}/.config/mastorss/config-example.json

{
    "example": {
        "instance": "botsin.space",
        "feedurl": "https:\/\/example.com\/feed.rss",
        "access_token": "123abc",
        "max_size": "400",
        "last_entry": "Example\n\nThis is an example.\n\nhttps:\/\/example.com\/12345.html\n\n#bot"
    }
}

Error codes

Same as mastodon-cpp

Copyright

Copyright © 2018 tastytea <tastytea@tastytea.de>.
License GPLv3: GNU GPL version 3 <https://www.gnu.org/licenses/gpl-3.0.html>.
This program comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to redistribute it under certain conditions.