Closed cmcginty closed 3 years ago
This is a wonderful tweak! Since SnapRAID does not natively support markdown formatting, I thought this could never happen! I was always sad when seeing those broken tables.
I can see only one downside: wrapped text is not formatted. Do you think there's a way to change the font? If not, I'll still merge: it's a great change.
Markdown does not have a way to change the font .. only the style like headings, bold, etc.
I don't understand the "wrapped text not formatted" issue. Do you have an example? If your device has a small screen and wraps the line, I don't think there is anything to do. The only solution is to to re-write all of the output from snapraid which would be very difficult and probably break after any new updates.
What I meant is
I tested the output on my smartphone with Gmail and I can read the email correctly.
If you look at the screen I posted the messages we write are formatted (above) but the sync command is not (below).
Oh, right. Yeah you can't have formatting inside of the code blocks. Since snapraid doesn't output markdown format anyway, it's a mute point. The one exception is line "Everything OK" that was adjusted to be bolded by the script. Maybe in that case just write a new line after the command output?
That's fine, I'll leave it as is. I made that message bold to add clarity but realized I never actually look at that part. So I'll merge, this is a very welcome change :)
This tweaks the email output to correct some issues with the markdown formatting. The main part is wrapping the
snapraid
output in code blocks. This makes the formatting a lot nicer and also fixes the status output so it's easy to read.I dropped the extra "echo" lines, since it doesn't impact the markdown output. If there is concern that it makes the text output worse, then I can add them back.