Add support for gifs as comment attachments. #3522

Closed
opened 2025-11-02 05:15:47 -06:00 by GiteaMirror · 5 comments
Owner

Originally created by @FelixK15 on GitHub (Jun 27, 2019).

Description

Adding support for gifs as attachments for comments would be of great help for our current real-time project since it makes it easier to convey eg. what an issue actually looks like on the users PC without having to write elaborate repro steps.

We're using gitea version 7f7c451.

Screenshots

image

Originally created by @FelixK15 on GitHub (Jun 27, 2019). ## Description Adding support for gifs as attachments for comments would be of great help for our current real-time project since it makes it easier to convey eg. what an issue actually looks like on the users PC without having to write elaborate repro steps. We're using gitea version 7f7c451. ## Screenshots ![image](https://user-images.githubusercontent.com/7531672/60258434-6c10b100-98d5-11e9-80f5-57ec3fee683a.png)
Author
Owner

@lunny commented on GitHub (Jun 27, 2019):

The file types could be customized.

@lunny commented on GitHub (Jun 27, 2019): The file types could be customized.
Author
Owner

@silverwind commented on GitHub (Jun 27, 2019):

Should be ALLOWED_TYPES in app.ini. It's documentation inside app.ini could be improved to state what the default value is.

@silverwind commented on GitHub (Jun 27, 2019): Should be `ALLOWED_TYPES` in `app.ini`. It's documentation inside `app.ini` could be improved to state what the default value is.
Author
Owner

@mrsdizzie commented on GitHub (Jun 28, 2019):

Per https://github.com/go-gitea/gitea/blob/master/custom/conf/app.ini.sample I believe it is

image/jpeg|image/png|application/zip|application/gzip

So to fix this issue add this to your app.ini:

[attachment]
ALLOWED_TYPES = image/jpeg|image/png|image/gif|application/zip|application/gzip
@mrsdizzie commented on GitHub (Jun 28, 2019): Per https://github.com/go-gitea/gitea/blob/master/custom/conf/app.ini.sample I believe it is ``` image/jpeg|image/png|application/zip|application/gzip ``` So to fix this issue add this to your app.ini: ``` [attachment] ALLOWED_TYPES = image/jpeg|image/png|image/gif|application/zip|application/gzip ```
Author
Owner

@silverwind commented on GitHub (Jun 29, 2019):

Ah, right it's attachment.ALLOWED_TYPES, I was looking at repository.upload.ALLOWED_TYPES earlier. Both look good documentation-wise, this issue is invalid.

@silverwind commented on GitHub (Jun 29, 2019): Ah, right it's `attachment.ALLOWED_TYPES`, I was looking at `repository.upload.ALLOWED_TYPES` earlier. Both look good documentation-wise, this issue is invalid.
Author
Owner

@FelixK15 commented on GitHub (Jul 1, 2019):

Thanks! That worked :)

@FelixK15 commented on GitHub (Jul 1, 2019): Thanks! That worked :)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#3522