Mercurial > hg > egg-tcls
changeset 532:15bbd5b2bd73
quotedb: Update example configuration.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Tue, 07 Jul 2020 14:28:33 +0300 |
parents | 137d61a0b5b7 |
children | 195db79c82a8 |
files | config.quotedb.example |
diffstat | 1 files changed, 67 insertions(+), 69 deletions(-) [+] |
line wrap: on
line diff
--- a/config.quotedb.example Tue Jul 07 14:22:47 2020 +0300 +++ b/config.quotedb.example Tue Jul 07 14:28:33 2020 +0300 @@ -4,23 +4,75 @@ # ########################################################################## +### +### Bind commands for each database etc. +### + +# Bind !quote -command for table "quotedb" +bind pub - !vitsi vitsi_cmd_pub +bind msg - !vitsi vitsi_cmd_msg +proc vitsi_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!vitsi" "quotedb" $unick $uhost $uhand $uchan $utext 1 } +proc vitsi_cmd_msg {unick uhost uhand utext} { qdb_command "!vitsi" "quotedb" $unick $uhost $uhand "" $utext 0 } +set qdb_messages(quotedb_fmt_get) "@2@ (#@1@)" +set qdb_messages(quotedb_urlprefix) "" +set qdb_messages(quotedb_name) "Vitsi" + + +# Bind !quote -command for table "kissa" +bind pub - !kissa kissa_cmd_pub +bind msg - !kissa kissa_cmd_msg +proc kissa_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!kissa" "kissadb" $unick $uhost $uhand $uchan $utext 1 } +proc kissa_cmd_msg {unick uhost uhand utext} { qdb_command "!kissa" "kissadb" $unick $uhost $uhand "" $utext 0 } +set qdb_messages(kissadb_fmt_get) "kissa @2@ (#@1@)" +set qdb_messages(kissadb_urlprefix) "" +set qdb_messages(kissadb_name) "Kissa" +set qdb_messages(kissadb_stats) "Kissa-tilastot: @1@ kissajuttua, @2@ äänestettyä kissamaisuutta." +set qdb_messages(kissadb_quote_does_not_exist) "Kissaa #@1@ ei ole olemassa." + + +bind pub - !spede spede_cmd_pub +bind msg - !spede spede_cmd_msg +proc spede_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!spede" "spededb" $unick $uhost $uhand $uchan $utext 1 } +proc spede_cmd_msg {unick uhost uhand utext} { qdb_command "!spede" "spededb" $unick $uhost $uhand "" $utext 0 } +set qdb_messages(spededb_urlprefix) "https://tnsp.org/spede/img/" +set qdb_messages(spededb_name) "Spede" +set qdb_messages(spededb_stats) "Spede-tilastot: @1@ spedeä, @2@ äänestettyä spedeä." +set qdb_messages(spededb_quote_does_not_exist) "Spedeä #@1@ ei ole." + + +bind pub - !mn mn_cmd_pub +bind msg - !mn mn_cmd_msg +proc mn_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!mn" "mndb" $unick $uhost $uhand $uchan $utext 1 } +proc mn_cmd_msg {unick uhost uhand utext} { qdb_command "!mn" "mndb" $unick $uhost $uhand "" $utext 0 } +set qdb_messages(mndb_urlprefix) "https://tnsp.org/mndb/img/" +set qdb_messages(mndb_name) "Nykäsismi" +set qdb_messages(mndb_stats) "Nykäs-tilastot: @1@ nykäsismiä, @2@ äänestettyä." +set qdb_messages(mndb_quote_does_not_exist) "Nykäsismiä #@1@ ei ole." + + +bind pub - !tuksu tuksu_cmd_pub +bind msg - !tuksu tuksu_cmd_msg +proc tuksu_cmd_pub {unick uhost uhand uchan utext} { qdb_command "!tuksu" "tuksudb" $unick $uhost $uhand $uchan $utext 1 } +proc tuksu_cmd_msg {unick uhost uhand utext} { qdb_command "!tuksu" "tuksudb" $unick $uhost $uhand "" $utext 0 } +set qdb_messages(tuksudb_urlprefix) "https://tnsp.org/tuksu/img/" +set qdb_messages(tuksudb_name) "Tuksu" +set qdb_messages(tuksudb_stats) "Tuksu-tilastot: @1@ tuksuilua, @2@ äänestettyä." +set qdb_messages(tuksudb_quote_does_not_exist) "Tuksuilua #@1@ ei ole." + + +### +### Settings +### # Channels where quote functionality is enabled # set qdb_channels "#foobar;#baz" # You can use * to match substrings or everything set qdb_channels "*" -### -### SQL database settings -### # Path and filename of the SQLite database set qdb_file "quotedb.sqlite" -### -### General settings -### - # Verbosity (1 = be verbose, 0 = be quiet) set qdb_verbose 0 @@ -35,14 +87,16 @@ set qdb_preferredmsg "PRIVMSG" -### -### Search/command related settings -### +# Maximum time (in minutes) after quote addition +# when user is still allowed to DELETE a quote set qdb_max_deltime 15 + +# Same, but for quote modification set qdb_max_modtime 30 -# Limit how many quotes should the "!<cmd> find" command show at most. +# Limit how many matches should the "!<cmd> find" command +# list at most in public searches set qdb_showmax_pub 3 # Same as above, but for private message search. @@ -50,12 +104,12 @@ # Limit min/max of !quote top <n> -set qdb_toplist_min 2 +set qdb_toplist_min 3 set qdb_toplist_max 5 ### -### Messages +### Message texts (informal, errors, etc.) ### array set qdb_messages { @@ -101,59 +155,3 @@ "quote_too_old" "@name@ quote #@1@ vanhempi kuin @2@ minuuttia, ei poisteta." "quote_does_not_exist" "Quotea #@1@ ei ole." } - - -### -### Bind commands for each database etc. -### - -# Bind !quote -command for table "quotedb" -bind pub - !vitsi vitsi_pub_cmd -bind msg - !vitsi vitsi_msg_cmd -proc vitsi_pub_cmd {unick uhost uhand uchan utext} { qdb_command "!vitsi" "quotedb" $unick $uhost $uhand $uchan $utext 1 } -proc vitsi_msg_cmd {unick uhost uhand utext} { qdb_command "!vitsi" "quotedb" $unick $uhost $uhand "" $utext 0 } -set qdb_messages(quotedb_fmt_get) "@2@ (#@1@)" -set qdb_messages(quotedb_urlprefix) "" -set qdb_messages(quotedb_name) "Vitsi" - - -# Bind !quote -command for table "kissa" -bind pub - !kissa kissa_pub_cmd -bind msg - !kissa kissa_msg_cmd -proc kissa_pub_cmd {unick uhost uhand uchan utext} { qdb_command "!kissa" "kissadb" $unick $uhost $uhand $uchan $utext 1 } -proc kissa_msg_cmd {unick uhost uhand utext} { qdb_command "!kissa" "kissadb" $unick $uhost $uhand "" $utext 0 } -set qdb_messages(kissadb_fmt_get) "kissa @2@ (#@1@)" -set qdb_messages(kissadb_urlprefix) "" -set qdb_messages(kissadb_name) "Kissa" -set qdb_messages(kissadb_stats) "Kissa-tilastot: @1@ kissajuttua, @2@ äänestettyä kissamaisuutta." -set qdb_messages(kissadb_quote_does_not_exist) "Kissaa #@1@ ei ole olemassa." - - -bind pub - !spede spede_pub_cmd -bind msg - !spede spede_msg_cmd -proc spede_pub_cmd {unick uhost uhand uchan utext} { qdb_command "!spede" "spededb" $unick $uhost $uhand $uchan $utext 1 } -proc spede_msg_cmd {unick uhost uhand utext} { qdb_command "!spede" "spededb" $unick $uhost $uhand "" $utext 0 } -set qdb_messages(spededb_urlprefix) "https://tnsp.org/spede/img/" -set qdb_messages(spededb_name) "Spede" -set qdb_messages(spededb_stats) "Spede-tilastot: @1@ spedeä, @2@ äänestettyä spedeä." -set qdb_messages(spededb_quote_does_not_exist) "Spedeä #@1@ ei ole." - - -bind pub - !mn mn_pub_cmd -bind msg - !mn mn_msg_cmd -proc mn_pub_cmd {unick uhost uhand uchan utext} { qdb_command "!mn" "mndb" $unick $uhost $uhand $uchan $utext 1 } -proc mn_msg_cmd {unick uhost uhand utext} { qdb_command "!mn" "mndb" $unick $uhost $uhand "" $utext 0 } -set qdb_messages(mndb_urlprefix) "https://tnsp.org/mndb/img/" -set qdb_messages(mndb_name) "Nykäsismi" -set qdb_messages(mndb_stats) "Nykäs-tilastot: @1@ nykäsismiä, @2@ äänestettyä." -set qdb_messages(mndb_quote_does_not_exist) "Nykäsismiä #@1@ ei ole." - - -bind pub - !tuksu tuksu_pub_cmd -bind msg - !tuksu tuksu_msg_cmd -proc tuksu_pub_cmd {unick uhost uhand uchan utext} { qdb_command "!tuksu" "tuksudb" $unick $uhost $uhand $uchan $utext 1 } -proc tuksu_msg_cmd {unick uhost uhand utext} { qdb_command "!tuksu" "tuksudb" $unick $uhost $uhand "" $utext 0 } -set qdb_messages(tuksudb_urlprefix) "https://tnsp.org/tuksu/img/" -set qdb_messages(tuksudb_name) "Tuksu" -set qdb_messages(tuksudb_stats) "Tuksu-tilastot: @1@ tuksuilua, @2@ äänestettyä." -set qdb_messages(tuksudb_quote_does_not_exist) "Tuksuilua #@1@ ei ole."