init gemini protocol implementation

This commit is contained in:
yggverse 2024-04-03 17:07:28 +03:00
parent 8418a56617
commit 1f96ca8a2c
11 changed files with 204 additions and 2422 deletions

View file

@ -21,7 +21,7 @@
}
}
},
"webui":
"gui":
{
"pagination":
{
@ -35,7 +35,7 @@
{
"url":{
"enabled":false,
"regex":"/.*/ui"
"regex":"/^gemini:\/\/.*/ui"
}
}
},
@ -59,9 +59,9 @@
"fields":
[
"url",
"title",
"description",
"keywords",
"h1",
"h2",
"h3",
"body"
],
"options":
@ -71,57 +71,6 @@
}
}
},
"footer":
{
"links":
[
{
"text":"0200::/7",
"attributes":
{
"title":"Search in 0200::/7 IPv6",
"href":"http://[201:23b4:991a:634d:8359:4521:5576:15b7]/yo/"
},
"index":
[
"http://[201:23b4:991a:634d:8359:4521:5576:15b7]/yo/index.sql"
]
},
{
"text":"yo.ygg",
"attributes":
{
"title":"Search in .ygg zone",
"href":"http://yo.ygg"
},
"index":
[
"http://yo.ygg/index.sql"
]
},
{
"text":"ygg.yo.index",
"attributes":
{
"title":"Search in .ygg zone",
"href":"http://ygg.yo.index"
},
"index":
[
"http://ygg.yo.index/index.sql"
]
},
{
"text":"GitHub",
"attributes":
{
"title":"Source code",
"href":"https://github.com/YGGverse/Yo"
},
"index":[]
}
]
},
"index":
{
"enabled":true
@ -161,119 +110,30 @@
"timeout":5,
"socket":
{
"201:5eb5:f061:678e:7565:6338:c02c:5251":80
"8.8.8.8":80
}
}
},
"curl":
"connection":
{
"connection":
{
"timeout":3
},
"download":
{
"size":
{
"max":10000024
}
}
"timeout":3,
"length":1048576,
"chunk":1
},
"queue":
{
"limit":1,
"delay":1
},
"selector":
"url":
{
"a:not([rel=nofollow])":
"external":true,
"regex":"/^gemini:\/\/.*/ui",
"skip":
{
"attribute":"href",
"external":false,
"regex":"/.*/ui"
},
"image":
{
"attribute":"src",
"external":false,
"regex":"/.*/ui"
},
"audio":
{
"attribute":"src",
"external":false,
"regex":"/.*/ui"
},
"video":
{
"attribute":"src",
"external":false,
"regex":"/.*/ui"
},
"script":
{
"attribute":"href",
"external":false,
"regex":"/.*/ui"
}
},
"skip":
{
"stripos":
{
"url":
"stripos":
[
"#",
"?",
"javascript:",
"mailto:",
"magnet:",
"xmpp:",
"/commit",
"/diff",
"/print",
"/raw",
"/cache",
"/download",
"/share",
"/explore",
"/register",
"/login",
"/password",
"/forgot",
"/restore",
"/account",
"/reply",
"/read",
"/compose",
"/comment",
"/add",
"/edit",
"/delete",
"/quote",
"/report",
"/export",
"/import",
"/mobile",
"/mwiki",
"/branch",
"/block",
"/transaction",
"/search",
"/tag",
"/page",
"/sort",
"/order",
"/pdf",
"/fb2",
"/mobi",
"/epub",
"/djvu",
"/_detail",
"/_media",
"/t/",
"/q/",
"/s/"
"?"
]
}
},
@ -297,28 +157,21 @@
"directory":"storage/snap",
"size":
{
"max":10000024
"max":1048576
},
"mime":
"meta":
{
"stripos":
[
"application/xhtml+xml",
"application/javascript",
"text/html",
"text/plain",
"text/css",
"image/webp",
"image/png",
"image/gif",
"image/ico"
"text/gemini",
"image/"
]
},
"url":
{
"stripos":
[
"http"
"gemini://"
]
}
},
@ -345,28 +198,21 @@
},
"size":
{
"max":10000024
"max":1048576
},
"mime":
"meta":
{
"stripos":
[
"application/xhtml+xml",
"application/javascript",
"text/html",
"text/plain",
"text/css",
"image/webp",
"image/png",
"image/gif",
"image/ico"
"text/gemini",
"image/"
]
},
"url":
{
"stripos":
[
"http"
"gemini://"
]
}
}