2019-07-25 10:03:45 +02:00
|
|
|
Mattermost BOT
|
|
|
|
==============
|
|
|
|
|
|
|
|
Read a RSS feed and post items in a mattermost channel.
|
|
|
|
|
|
|
|
Installation
|
|
|
|
------------
|
|
|
|
|
|
|
|
```bash
|
|
|
|
$ git clone https://gitnet.fr/deblan/mattermost-bot.git
|
|
|
|
$ cd mattermost-bot
|
|
|
|
$ cp config.ini.dist config.ini
|
|
|
|
```
|
|
|
|
|
2019-07-25 10:54:36 +02:00
|
|
|
Example of `config.ini` :
|
2019-07-25 10:03:45 +02:00
|
|
|
|
|
|
|
```ini
|
|
|
|
[feed]
|
|
|
|
url = "https://www.example.com/feed/"
|
|
|
|
|
|
|
|
[cache]
|
|
|
|
file = 'cache.db'
|
|
|
|
|
|
|
|
[mattermost]
|
|
|
|
hook_url = "https://mattermost.example.com/hooks/1234567890abcdefghijklm"
|
|
|
|
message_template = "« %1$s » %2$s #foo #bar"
|
|
|
|
```
|
|
|
|
|
2019-07-25 10:52:22 +02:00
|
|
|
Then run `php index.php`.
|
|
|
|
|
|
|
|
You can specify the path of the configuration using the option `-c` : `php index.php -c /path/to/config.ini`.
|