aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOmar Polo <op@omarpolo.com>2022-04-08 15:36:59 +0000
committerOmar Polo <op@omarpolo.com>2022-04-08 15:36:59 +0000
commit93cab6dc784ac671f7d536deb0a16b9abcfdf420 (patch)
tree911135d3574c60e837452e96738663cf18436191
parent6d362b355629b136ab2192a64b3deb1c3d28d99b (diff)
document the implicit mapping for text/gemini
and remove the explicit mapping from the documentation and test files.
-rw-r--r--gmid.conf.514
-rw-r--r--regress/example.mime.types4
-rw-r--r--site/faq.gmi2
3 files changed, 11 insertions, 9 deletions
diff --git a/gmid.conf.5 b/gmid.conf.5
index e8515be..1a5dc2a 100644
--- a/gmid.conf.5
+++ b/gmid.conf.5
@@ -532,7 +532,7 @@ By default
.Nm gmid
uses the following mapping if no
.Ic types
-block is used:
+block is defined:
.Bl -tag -offset indent -width 15m -compact
.It application/pdf
pdf
@@ -553,6 +553,16 @@ diff patch
.It text/xml
xml
.El
+.Pp
+As an exception,
+.Nm gmid
+uses the MIME type
+.Ar text/gemini
+for file extensions
+.Ar gemini
+or
+.Ar gmi
+if no mapping was found.
.Sh EXAMPLES
The following is an example of a possible configuration for a site
that enables only TLSv1.3, adds the MIME types mapping from
@@ -564,8 +574,6 @@ ipv6 on # enable ipv6
protocols "tlsv1.3"
types {
- text/gemini gemini gmi
-
include "/usr/share/misc/mime.types"
}
diff --git a/regress/example.mime.types b/regress/example.mime.types
index c7b6833..b7c8e2a 100644
--- a/regress/example.mime.types
+++ b/regress/example.mime.types
@@ -7,7 +7,3 @@ application/x-perl pl pm
text/x-mandoc 1 2 3 4 5 6 7 8 9
text/x-mandoc 3bsd
-
-# this needs to be present because `types' overrides
-# the built-in list.
-text/gemini gemini gmi
diff --git a/site/faq.gmi b/site/faq.gmi
index b73ed30..87a0067 100644
--- a/site/faq.gmi
+++ b/site/faq.gmi
@@ -13,8 +13,6 @@ gmid, like many other servers, uses a list of known file extensions to decide wh
``` example of how to use the type rule in the configuration file
types {
- text/gemini gemini gmi
-
application/postscript ps eps ai
application/rss+xml rss