Skip to content

Commit

Permalink
Merge pull request #14 from stapelberg/zstd
Browse files Browse the repository at this point in the history
Add zstandard (zstd, .zst) support
  • Loading branch information
lpar authored Jun 5, 2020
2 parents d05b26a + a10e983 commit 5fe469a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion fileserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ import (
)

// List of encodings we would prefer to use, in order of preference, best first.
var preferredEncodings = []string{"br", "gzip", "identity"}
var preferredEncodings = []string{"zstd", "br", "gzip", "identity"}

// File extension to use for different encodings.
func extensionForEncoding(encname string) string {
switch encname {
case "zstd":
return ".zst"
case "gzip":
return ".gz"
case "br":
Expand Down

0 comments on commit 5fe469a

Please sign in to comment.