mautrix / gmessages

A Matrix-Google Messages puppeting bridge
GNU Affero General Public License v3.0
80 stars 9 forks source link

Add user options to disable battery and certain connected messages #23

Open seang96 opened 3 months ago

seang96 commented 3 months ago

This is an attempt of supporting issue #17.

I wanted to make the changes not break existing configurations. and the options to be toggled per user, so I added to "Connection Management" section of commands the following commands:

  1. toggle-battery-notifications - Silence Battery statuses.
  2. toggle-verbose-notifications - Silence Connected statuses when session changes and no data received recently.

The battery one toggles both "Phone battery restored" and "Your phone's battery is low" for the user.

The goal of toggle-verbose-notifications is to silence updates when everything is working as expected. If the status "Connected to Google Messages" is due to a disconnection longer for 5 minutes for example it will still show, but it will hide it when a session changes or when there is simply no activity.