~jae/hsl-matrix-notifier

The notification service for HSL.
b6b4d191 — Jae Lo Presti (DN0) 1 year, 11 months ago
CI: add automatic builds
29cb2c48 — Jae Lo Presti (DN0) 2 years ago
README: update roadmap
20a310b7 — Jae Lo Presti (DN0) 2 years ago
README: add dev guide

refs

main
browse  log 

clone

read-only
https://git.sr.ht/~jae/hsl-matrix-notifier
read/write
git@git.sr.ht:~jae/hsl-matrix-notifier

You can also use your local clone with git send-email.

#HSL Matrix Notifier

Sponsored

A simple bot program made to notify Matrix room(s) of HSL disruptions.

#Running

You can easily use the program by following those steps:

git clone https://git.jae.fi/jae/hsl-matrix-notifier.git
vim docker-compose.yml

And in the docker-compose.yml file:

version: 3.9

services:
  hslcheck:
    build: ./hsl-matrix-notifier/
    environment:
      - MATRIX_TOKEN=supersecret
      - MATRIX_HOMESERVER=matrix.server.tld
      - HSL_NOTIFICATION_LANGUAGE=fi

And then do docker compose up -d and you have now a working bot.
It will query the API every 12 hours.

Note: it is recommended to use a .env file instead of putting everything in the docker-compose.yml file.

#Dev setup

Dev setup:

git clone https://git.jae.fi/jae/hsl-matrix-notifier.git
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt

All set (don't forget to set your env variables with Matrix homeserver & token)!

#Roadmap

Roadmap of the project:

  • Only new events shown (RSS-feed style)
  • Per-room language
  • More customizable transport methods (select from bus, train, metro, tram)
  • Maubot plugin version
  • Hemppa plugin version