From 5d7fbcc47fced289b72edbb5ddde2eb4f99b8203 Mon Sep 17 00:00:00 2001 From: josh-stengg Date: Mon, 5 Aug 2024 00:34:56 +0000 Subject: [PATCH] Clarify the valid values for COMPRESSION_LEVEL (#42) Remove the comment that values must be preceded with a `-` and add details about default and Huffman compression along with links to the Golang documentation. Reviewed-on: https://gitea.com/gitea/docs/pulls/42 Reviewed-by: Lunny Xiao Co-authored-by: josh-stengg Co-committed-by: josh-stengg --- docs/administration/logging-config.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docs/administration/logging-config.md b/docs/administration/logging-config.md index 30dffafc..4b86712f 100644 --- a/docs/administration/logging-config.md +++ b/docs/administration/logging-config.md @@ -182,9 +182,8 @@ Settings: `MAX_SIZE_SHIFT` defines the maximum size of a file by left shifting 1 the given number of times (`1 << x`). The exact behavior at the time of v1.17.3 can be seen [here](https://github.com/go-gitea/gitea/blob/v1.17.3/modules/setting/log.go#L185). -The useful values of `COMPRESSION_LEVEL` are from 1 to (and including) 9, where higher numbers mean better compression. +The useful values of `COMPRESSION_LEVEL` are from 1 (best speed) to 9 (best compression). [DefaultCompression](https://pkg.go.dev/compress/gzip#pkg-constants) (-1) and [HuffmanOnly](https://pkg.go.dev/compress/flate#HuffmanOnly) (-2) can also be chosen. Beware that better compression might come with higher resource usage. -Must be preceded with a `-` sign. ### Conn mode