Closed agx closed 3 months ago
I'm not sure if this is the best solution. The problem is if i open up my terminal and i define a matrix end point. With today's design, i can just do:
# my.test.script.sh can have entries like:
# echo '' > /dev/null
# my.tool 2>&1 >file <input
# ...
# apprise will deliver everything as what you see is what you get
cat my.test.script.sh | apprise -g matrix
If Matrix default is html
, i will need to check and see if the <
and other characters fed cause any disturbance (get treated as broken HTML, etc). If it still looks presentable, then perhaps this is okay.
Today if you want HTML data, you just need to add ?format=html
to the end of your matrix://
URL.
But i'd be curious on your thoughts/rational (because to your point, email defaults to html
and things work fine). Other step would be to verify that if you default to html
that someone who types ?format=text
it still allows one to send content the old way too.
Thinking about this some more I guess what was actually after is having the "raw" text in body
and (if it contains markdown formatting) having a formatted_body
with HTML (and having "format": "org.matrix.custom.html"
set too in this case) . This would match what other clients (e.g. Element) do which works with ?format=markdown
so all is good from my side. Thanks!
This ensures the org.matrix.custom.html is added which is usually what we want as otherwise no formatting is applied.
Description:
Set default notifiction format to HTML
This ensures the
org.matrix.custom.html
element is added which is usually what we want as otherwise no formatting is applied.I assume there's a reason for not doing so by default but looking around I couldn't spot any as other plugins set this too.
Checklist
flake8
)Testing
Anyone can help test this source code as follows: