Better readable IRC messages on Telegram by putting Nickname in a blockquote part#447
Open
oliveratgithub wants to merge 2 commits intoRITlug:mainfrom
Open
Better readable IRC messages on Telegram by putting Nickname in a blockquote part#447oliveratgithub wants to merge 2 commits intoRITlug:mainfrom
oliveratgithub wants to merge 2 commits intoRITlug:mainfrom
Conversation
Introduces a new optional `QUOTE_NICKNAME=true` setting, that adjusts how IRC messages - particularly the nickname part - are rendered when bridged to Telegram: instead of a whole unformatted string, it uses the supported `<blockquote>`-formatting for the Telegram messages. This results in the sending IRC nickname to be better visible, but also clearly distinguishable from the IRC user's effective Text Message. - Telegram message default behaviour / before: `<ircnick> Hello from IRC to Telegram` - New behaviour and format, if this mode is enabled, will rather look as follows: ``` > <ircnick> Hello from IRC to Telegram ``` For this to work: - the message's parse_mode has to be set to `HTML` - and this requires proper HTML-escaping / HTML-tag removal on the IRC nickname & message parts, before calling the Telegram Bot API sendMessage command. - The StripHTML() func invoked for that, was taken from here: https://go.dev/play/p/fqHzlCJa9ta (L31-35)
+ A few Go syntax validation improvements
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Introduces a new optional
QUOTE_NICKNAME=truesetting, that adjusts how IRC messages - particularly the nickname part - are rendered when bridged to Telegram.Instead of a whole unformatted string, it uses the supported
<blockquote>-formatting for the Telegram messages. This results in the sending IRC nickname to be better visible, but also clearly distinguishable from the IRC user's effective Text Message.Comparison
<ircnick> Hello from IRC to TelegramContext
For this to work:
HTML