From 8eba27c79257c6bc68cefbdffbb36d3596e6d3ee Mon Sep 17 00:00:00 2001 From: Mario Lubenka Date: Sun, 2 Jun 2019 08:40:12 +0200 Subject: Repository avatar fallback configuration (#7087) * Only show repository avatar in list when one was selected Signed-off-by: Mario Lubenka * Adds fallback configuration option for repository avatar Signed-off-by: Mario Lubenka * Implements repository avatar fallback Signed-off-by: Mario Lubenka * Adds admin task for deleting generated repository avatars Signed-off-by: Mario Lubenka * Solve linting issues Signed-off-by: Mario Lubenka * Save avatar before updating database * Linting * Update models/repo.go Co-Authored-By: zeripath --- docs/content/doc/advanced/config-cheat-sheet.en-us.md | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'docs') diff --git a/docs/content/doc/advanced/config-cheat-sheet.en-us.md b/docs/content/doc/advanced/config-cheat-sheet.en-us.md index 052ced6e2a..ecc196c86e 100644 --- a/docs/content/doc/advanced/config-cheat-sheet.en-us.md +++ b/docs/content/doc/advanced/config-cheat-sheet.en-us.md @@ -292,6 +292,11 @@ Values containing `#` or `;` must be quoted using `` ` `` or `"""`. [http://www.libravatar.org](http://www.libravatar.org)). - `AVATAR_UPLOAD_PATH`: **data/avatars**: Path to store user avatar image files. - `REPOSITORY_AVATAR_UPLOAD_PATH`: **data/repo-avatars**: Path to store repository avatar image files. +- `REPOSITORY_AVATAR_FALLBACK`: **none**: How Gitea deals with missing repository avatars + - none = no avatar will be displayed + - random = random avatar will be generated + - image = default image will be used (which is set in `REPOSITORY_AVATAR_DEFAULT_IMAGE`) +- `REPOSITORY_AVATAR_FALLBACK_IMAGE`: **/img/repo_default.png**: Image used as default repository avatar (if `REPOSITORY_AVATAR_FALLBACK` is set to image and none was uploaded) - `AVATAR_MAX_WIDTH`: **4096**: Maximum avatar image width in pixels. - `AVATAR_MAX_HEIGHT`: **3072**: Maximum avatar image height in pixels. - `AVATAR_MAX_FILE_SIZE`: **1048576** (1Mb): Maximum avatar image file size in bytes. -- cgit v1.2.3