From: Ian Kelling Date: Wed, 22 May 2019 02:34:24 +0000 (-0400) Subject: Restore namazu template files. X-Git-Url: https://vcs.fsf.org/?p=mharc.git;a=commitdiff_plain;h=bfab7d846265d174e11228292478474375e7a2ef Restore namazu template files. Andrew removed this as part of upgrading namazu and likely to deal with the issue that javascript was required to do subsequent searches. But this made subsequent searches broken in a more obvious way with or without javascript, and also made it so you couldn't sort the results. I think I can fix the javascript issue. --- diff --git a/.gitignore b/.gitignore index 9a4930c..d9f6227 100644 --- a/.gitignore +++ b/.gitignore @@ -6,7 +6,6 @@ /.bash* /.gitconfig /log -/namazu # This is debug log file when "The \x22negative number\x22 problem occurred.\n" happens. # todo: we don't rotate this afaik, we should diff --git a/cgi-bin/template b/cgi-bin/template deleted file mode 120000 index 024a99c..0000000 --- a/cgi-bin/template +++ /dev/null @@ -1 +0,0 @@ -/usr/share/namazu/template/ \ No newline at end of file diff --git a/cgi-bin/template/NMZ.body b/cgi-bin/template/NMZ.body new file mode 100644 index 0000000..d9eef22 --- /dev/null +++ b/cgi-bin/template/NMZ.body @@ -0,0 +1,190 @@ +

Query

+ +

Long messages and words are ignored

+

+Messages longer than 100,000 letters or 500,000 bytes are ignored. Words +longer than 40 characters are ignored. Attachments are ignored. +

+ +

Single term query

+

+The query specifies only one term for retrieving all +documents which contain the term. e.g., +

+ +

+namazu +

+ +

AND query

+ +

+The query specifies two or more terms for retrieving all +documents which contain both terms. You can insert the +and operator between the terms. e.g., +

+ +

+Linux and Netscape +

+ +

+You can ommit the and operator. Terms which is +separated by one ore more spaces is assumed to be AND query. +

+ +

OR query

+

+The query specifies two or more terms for retrieving all +documents which contain either term. You can insert the +or operator between the terms. +e.g., +

+ +

+Linux or FreeBSD +

+ +

NOT query

+

+The query specifies two or more terms for retrieving all +documents which contain a first term but does't contain the +following terms. You can insert the not +operator between the terms to do NOT query. e.g., +

+ +

+Linux not UNIX +

+ + +

Grouping

+

+You can group queries by surrounding them by +parentheses. The parentheses should be separated by one or +more spaces. e.g., +

+ +

+( Linux or FreeBSD ) and Netscape not Windows +

+ +

Phrase searching

+

+You can search for a phrase which consists of two or more terms +by surrounding them with double quotes like +"..." or with braces like {...}. +In Namazu, precision of phrase searching is not 100 %, +so it causes wrong results occasionally. e.g., +

+ +

+{GNU Emacs} +

+ + + +

Substring matching

+

+The are three types of substring matching searching. +

+ +
+
Prefix matching +
inter* (terms which begin with inter) +
Inside matching +
*text* (terms which contain text) +
Suffix matching +
*net (terms which terminated +with net) +
+ + +

Regular expressions

+ +

+You can use regular expressions for pattern matching. The +regular expressions must be surrounded by slashes like /.../. Namazu uses Ruby's regular +regular expressions engine. It offers generally Perl compatible flavor. +e.g., +

+ +

+/pro(gram|blem)s?/ +

+ + +

Field-specified searching

+

+You can limit your search to specific fields such as +Subject:, From:, +Message-Id:. It's especially convenient for +Mail/News documents. e.g., +

+ + + +

Notes

+ + + diff --git a/cgi-bin/template/NMZ.body.in b/cgi-bin/template/NMZ.body.in new file mode 100644 index 0000000..d9eef22 --- /dev/null +++ b/cgi-bin/template/NMZ.body.in @@ -0,0 +1,190 @@ +

Query

+ +

Long messages and words are ignored

+

+Messages longer than 100,000 letters or 500,000 bytes are ignored. Words +longer than 40 characters are ignored. Attachments are ignored. +

+ +

Single term query

+

+The query specifies only one term for retrieving all +documents which contain the term. e.g., +

+ +

+namazu +

+ +

AND query

+ +

+The query specifies two or more terms for retrieving all +documents which contain both terms. You can insert the +and operator between the terms. e.g., +

+ +

+Linux and Netscape +

+ +

+You can ommit the and operator. Terms which is +separated by one ore more spaces is assumed to be AND query. +

+ +

OR query

+

+The query specifies two or more terms for retrieving all +documents which contain either term. You can insert the +or operator between the terms. +e.g., +

+ +

+Linux or FreeBSD +

+ +

NOT query

+

+The query specifies two or more terms for retrieving all +documents which contain a first term but does't contain the +following terms. You can insert the not +operator between the terms to do NOT query. e.g., +

+ +

+Linux not UNIX +

+ + +

Grouping

+

+You can group queries by surrounding them by +parentheses. The parentheses should be separated by one or +more spaces. e.g., +

+ +

+( Linux or FreeBSD ) and Netscape not Windows +

+ +

Phrase searching

+

+You can search for a phrase which consists of two or more terms +by surrounding them with double quotes like +"..." or with braces like {...}. +In Namazu, precision of phrase searching is not 100 %, +so it causes wrong results occasionally. e.g., +

+ +

+{GNU Emacs} +

+ + + +

Substring matching

+

+The are three types of substring matching searching. +

+ +
+
Prefix matching +
inter* (terms which begin with inter) +
Inside matching +
*text* (terms which contain text) +
Suffix matching +
*net (terms which terminated +with net) +
+ + +

Regular expressions

+ +

+You can use regular expressions for pattern matching. The +regular expressions must be surrounded by slashes like /.../. Namazu uses Ruby's regular +regular expressions engine. It offers generally Perl compatible flavor. +e.g., +

+ +

+/pro(gram|blem)s?/ +

+ + +

Field-specified searching

+

+You can limit your search to specific fields such as +Subject:, From:, +Message-Id:. It's especially convenient for +Mail/News documents. e.g., +

+ + + +

Notes

+ + + diff --git a/cgi-bin/template/NMZ.body.in.dist b/cgi-bin/template/NMZ.body.in.dist new file mode 100644 index 0000000..f7706f1 --- /dev/null +++ b/cgi-bin/template/NMZ.body.in.dist @@ -0,0 +1,184 @@ +

Query

+ +

Single term query

+

+The query specifies only one term for retrieving all +documents which contain the term. e.g., +

+ +

+namazu +

+ +

AND query

+ +

+The query specifies two or more terms for retrieving all +documents which contain both terms. You can insert the +and operator between the terms. e.g., +

+ +

+Linux and Netscape +

+ +

+You can ommit the and operator. Terms which is +separated by one ore more spaces is assumed to be AND query. +

+ +

OR query

+

+The query specifies two or more terms for retrieving all +documents which contain either term. You can insert the +or operator between the terms. +e.g., +

+ +

+Linux or FreeBSD +

+ +

NOT query

+

+The query specifies two or more terms for retrieving all +documents which contain a first term but does't contain the +following terms. You can insert the not +operator between the terms to do NOT query. e.g., +

+ +

+Linux not UNIX +

+ + +

Grouping

+

+You can group queries by surrounding them by +parentheses. The parentheses should be separated by one or +more spaces. e.g., +

+ +

+( Linux or FreeBSD ) and Netscape not Windows +

+ +

Phrase searching

+

+You can search for a phrase which consists of two or more terms +by surrounding them with double quotes like +"..." or with braces like {...}. +In Namazu, precision of phrase searching is not 100 %, +so it causes wrong results occasionally. e.g., +

+ +

+{GNU Emacs} +

+ + + +

Substring matching

+

+The are three types of substring matching searching. +

+ +
+
Prefix matching +
inter* (terms which begin with inter) +
Inside matching +
*text* (terms which contain text) +
Suffix matching +
*net (terms which terminated +with net) +
+ + +

Regular expressions

+ +

+You can use regular expressions for pattern matching. The +regular expressions must be surrounded by slashes like /.../. Namazu uses Ruby's regular +regular expressions engine. It offers generally Perl compatible flavor. +e.g., +

+ +

+/pro(gram|blem)s?/ +

+ + +

Field-specified searching

+

+You can limit your search to specific fields such as +Subject:, From:, +Message-Id:. It's especially convenient for +Mail/News documents. e.g., +

+ + + +

Notes

+ + + diff --git a/cgi-bin/template/NMZ.foot b/cgi-bin/template/NMZ.foot new file mode 100644 index 0000000..6e5abdb --- /dev/null +++ b/cgi-bin/template/NMZ.foot @@ -0,0 +1,7 @@ +
+
+This search system is powered by +Namazu +
+ + diff --git a/cgi-bin/template/NMZ.foot.in b/cgi-bin/template/NMZ.foot.in new file mode 100644 index 0000000..6e5abdb --- /dev/null +++ b/cgi-bin/template/NMZ.foot.in @@ -0,0 +1,7 @@ +
+
+This search system is powered by +Namazu +
+ + diff --git a/cgi-bin/template/NMZ.foot.in.dist b/cgi-bin/template/NMZ.foot.in.dist new file mode 100644 index 0000000..6e5abdb --- /dev/null +++ b/cgi-bin/template/NMZ.foot.in.dist @@ -0,0 +1,7 @@ +
+
+This search system is powered by +Namazu +
+ + diff --git a/cgi-bin/template/NMZ.head b/cgi-bin/template/NMZ.head new file mode 100644 index 0000000..e9f2743 --- /dev/null +++ b/cgi-bin/template/NMZ.head @@ -0,0 +1,81 @@ + + +Mail Archive Search + + + + + +
+

Search String: + + + +Display: + +Description: + +Sort: + +

+
diff --git a/cgi-bin/template/NMZ.head.in b/cgi-bin/template/NMZ.head.in new file mode 100644 index 0000000..6d7f091 --- /dev/null +++ b/cgi-bin/template/NMZ.head.in @@ -0,0 +1,81 @@ + + +Mail Archive Search + + + + + +
+

Search String: + + + +Display: + +Description: + +Sort: + +

+
diff --git a/cgi-bin/template/NMZ.head.in.dist b/cgi-bin/template/NMZ.head.in.dist new file mode 100644 index 0000000..6d7f091 --- /dev/null +++ b/cgi-bin/template/NMZ.head.in.dist @@ -0,0 +1,81 @@ + + +Mail Archive Search + + + + + +
+

Search String: + + + +Display: + +Description: + +Sort: + +

+
diff --git a/cgi-bin/template/NMZ.result.normal b/cgi-bin/template/NMZ.result.normal new file mode 100644 index 0000000..5830a7c --- /dev/null +++ b/cgi-bin/template/NMZ.result.normal @@ -0,0 +1,5 @@ +
${namazu::counter}. ${title} (score: ${namazu::score}) +
Author: HIDDEN +
Date: ${date} +
${summary} +
${uri} (${size} bytes)

diff --git a/cgi-bin/template/NMZ.result.normal.in b/cgi-bin/template/NMZ.result.normal.in new file mode 100644 index 0000000..5830a7c --- /dev/null +++ b/cgi-bin/template/NMZ.result.normal.in @@ -0,0 +1,5 @@ +
${namazu::counter}. ${title} (score: ${namazu::score}) +
Author: HIDDEN +
Date: ${date} +
${summary} +
${uri} (${size} bytes)

diff --git a/cgi-bin/template/NMZ.result.normal.in.dist b/cgi-bin/template/NMZ.result.normal.in.dist new file mode 100644 index 0000000..cd8d609 --- /dev/null +++ b/cgi-bin/template/NMZ.result.normal.in.dist @@ -0,0 +1,5 @@ +
${namazu::counter}. ${title} (score: ${namazu::score}) +
Author: ${author} +
Date: ${date} +
${summary} +
${uri} (${size} bytes)

diff --git a/cgi-bin/template/NMZ.result.short b/cgi-bin/template/NMZ.result.short new file mode 100644 index 0000000..7f087a9 --- /dev/null +++ b/cgi-bin/template/NMZ.result.short @@ -0,0 +1,2 @@ +
${namazu::counter}. ${title} (score: ${namazu::score}) +
${uri} (${size} bytes)

diff --git a/cgi-bin/template/NMZ.result.short.in b/cgi-bin/template/NMZ.result.short.in new file mode 100644 index 0000000..7f087a9 --- /dev/null +++ b/cgi-bin/template/NMZ.result.short.in @@ -0,0 +1,2 @@ +
${namazu::counter}. ${title} (score: ${namazu::score}) +
${uri} (${size} bytes)

diff --git a/cgi-bin/template/NMZ.result.short.in.dist b/cgi-bin/template/NMZ.result.short.in.dist new file mode 100644 index 0000000..7f087a9 --- /dev/null +++ b/cgi-bin/template/NMZ.result.short.in.dist @@ -0,0 +1,2 @@ +
${namazu::counter}. ${title} (score: ${namazu::score}) +
${uri} (${size} bytes)

diff --git a/cgi-bin/template/NMZ.tips b/cgi-bin/template/NMZ.tips new file mode 100644 index 0000000..b19d4d6 --- /dev/null +++ b/cgi-bin/template/NMZ.tips @@ -0,0 +1,60 @@ +

Tips on searching

+ +

+If you have trouble with searching, you can check the following tips. +

+ + diff --git a/cgi-bin/template/NMZ.tips.in b/cgi-bin/template/NMZ.tips.in new file mode 100644 index 0000000..b19d4d6 --- /dev/null +++ b/cgi-bin/template/NMZ.tips.in @@ -0,0 +1,60 @@ +

Tips on searching

+ +

+If you have trouble with searching, you can check the following tips. +

+ + diff --git a/cgi-bin/template/NMZ.tips.in.dist b/cgi-bin/template/NMZ.tips.in.dist new file mode 100644 index 0000000..b19d4d6 --- /dev/null +++ b/cgi-bin/template/NMZ.tips.in.dist @@ -0,0 +1,60 @@ +

Tips on searching

+ +

+If you have trouble with searching, you can check the following tips. +

+ +