Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature] Better discord formatting, size limit workaround #2723

Open
Reginald-Gillespie opened this issue Oct 17, 2024 · 1 comment
Open
Labels
enhancement New feature or request

Comments

@Reginald-Gillespie
Copy link

Reginald-Gillespie commented Oct 17, 2024

Version and OS
v0.46.03 on linux/docker

Is your feature request related to a problem? Please describe.
The change summary sent to discord webhooks is always cut off by discord's 2000 char limit.

Describe the solution you'd like
A .txt file upload of the changes would allow it to be millions of chars longer.
The downside is that it would take a discord bot to send which is more complex to setup (opening discord devs tab, creating new bot, adding it to the server, grabbing the token), but shouldn't be hard to implement. On detecting a change, have a queue of messages it adds to that the bot should upload as .txt files. The bot could either be always online, or it could login to the bot any time the queue has messages, and log out a minute after the queue is empty.

With the file upload, you could even name the file ending in .diff and use the standard git formatting for changed lines, and it will look like this:
image

Technically you could (I know I technically should open a second issue for this) get this same rendering with the current system if you wrap the changes in three backticks with the word diff after the first three like so:

```diff
Before
+ Addition
- Subtration
After
```

Just gotta make sure that you don't trim the last three backticks off when limiting the message size to 2000 chars.

Describe the use-case and give concrete real-world examples
I think I've been clear enough.

@Reginald-Gillespie Reginald-Gillespie added the enhancement New feature or request label Oct 17, 2024
@Reginald-Gillespie
Copy link
Author

Formatting comments are similar to #2554, file upload idea still applies.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant