From d3c33dc6e46d804552b38973b370c1d60d5a2642 Mon Sep 17 00:00:00 2001 From: TheTuzu Date: Thu, 23 Mar 2023 18:34:32 +0100 Subject: [PATCH 01/23] Added Catppucin theme --- settings.php | 3 ++- static/css/catppuccin.css | 26 ++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 static/css/catppuccin.css diff --git a/settings.php b/settings.php index df150f6..362627b 100644 --- a/settings.php +++ b/settings.php @@ -61,7 +61,8 @@ - "; + + "; if (isset($_COOKIE["theme"])) { diff --git a/static/css/catppuccin.css b/static/css/catppuccin.css new file mode 100644 index 0000000..92ba358 --- /dev/null +++ b/static/css/catppuccin.css @@ -0,0 +1,26 @@ +:root { + --main-bg: #1E1E2E; + --main-fg: #CDD6F4; + + --result-link-fg: #89B4FA; + --result-fg: #B4B3FE; + + --button-bg: #313244; + + --special-result-border: opacity 50; + --special-text-background: #44475A; + --special-text-color: #CDD6F4; + + --search-container-text-color: #CDD6F4; + --search-container-background-color: #313244; + --search-container-background-border: #B4BEFE; + + --search-form-background-color: #181825; + + --border: #B4B3FE; + + --footer-fg: #A6ADC8; + --footer-bg: #313244; + + color-scheme: dark; +} From d04315009e5686206d3fbf88606ce9ee323230d3 Mon Sep 17 00:00:00 2001 From: hnhx Date: Fri, 24 Mar 2023 09:39:52 +0100 Subject: [PATCH 02/23] added number of results option, fixed a theme name --- config.php.example | 1 + engines/google/text.php | 10 ++++------ settings.php | 6 +++++- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/config.php.example b/config.php.example index 3d69fd6..be4fc64 100644 --- a/config.php.example +++ b/config.php.example @@ -7,6 +7,7 @@ // Google results will be in this language "google_language_site" => "", "google_language_results" => "", + "google_number_of_results" => 10, // You can set a language for results in wikipedia "wikipedia_language" => "en", diff --git a/engines/google/text.php b/engines/google/text.php index 56fb1ae..b18a504 100644 --- a/engines/google/text.php +++ b/engines/google/text.php @@ -10,23 +10,21 @@ $domain = $config->google_domain; $site_language = isset($_COOKIE["google_language_site"]) ? trim(htmlspecialchars($_COOKIE["google_language_site"])) : $config->google_language_site; $results_language = isset($_COOKIE["google_language_results"]) ? trim(htmlspecialchars($_COOKIE["google_language_results"])) : $config->google_language_results; + $number_of_results = isset($_COOKIE["google_number_of_results"]) ? trim(htmlspecialchars($_COOKIE["google_number_of_results"])) : $config->google_number_of_results; $url = "https://www.google.$domain/search?q=$query_encoded&start=$page"; if (3 > strlen($site_language) && 0 < strlen($site_language)) - { $url .= "&hl=$site_language"; - } if (3 > strlen($results_language) && 0 < strlen($results_language)) - { $url .= "&lr=lang_$results_language"; - } + + if (3 > strlen($number_of_results) && 0 < strlen($number_of_results)) + $url .= "&num=$number_of_results"; if (isset($_COOKIE["safe_search"])) - { $url .= "&safe=medium"; - } $google_ch = curl_init($url); curl_setopt_array($google_ch, $config->curl_settings); diff --git a/settings.php b/settings.php index 362627b..bca23e1 100644 --- a/settings.php +++ b/settings.php @@ -62,7 +62,7 @@ - "; + "; if (isset($_COOKIE["theme"])) { @@ -115,6 +115,10 @@ echo isset($_COOKIE["google_language_results"]) ? htmlspecialchars($_COOKIE["google_language_results"]) : $config->google_language_results; ?>"> +
+ + google_number_of_results; ?>" > +
> From e4178913bd8bc3a1d9f1260a77a49e06c4bb6024 Mon Sep 17 00:00:00 2001 From: Revvy Date: Sun, 26 Mar 2023 19:51:29 -0400 Subject: [PATCH 03/23] remove bibliogram --- config.php.example | 6 ------ docker/README.md | 1 - docker/attributes.sh | 1 - docker/php/config.php | 6 ------ docker/php/php.dockerfile | 1 - misc/tools.php | 6 ------ 6 files changed, 21 deletions(-) diff --git a/config.php.example b/config.php.example index be4fc64..9f9eeb2 100644 --- a/config.php.example +++ b/config.php.example @@ -32,12 +32,6 @@ "original_name" => "YouTube", "original_url" => "youtube.com" ), - "bibliogram" => array( - "instance_url" => "", - "project_url" => "https://git.sr.ht/~cadence/bibliogram-docs/tree/master/docs/Instances.md", - "original_name" => "Instagram", - "original_url" => "instagram.com" - ), "rimgo" => array( "instance_url" => "", "project_url" => "https://codeberg.org/video-prize-ranch/rimgo#instances", diff --git a/docker/README.md b/docker/README.md index b7bc5d6..f0c5cb9 100644 --- a/docker/README.md +++ b/docker/README.md @@ -107,7 +107,6 @@ This docker image was developed with high configurability in mind, so here is th | Variables | Default | Examples | Description | |:----------|:-------------|:---------|:------| | APP_INVIDIOUS | "" | string | Integration with external self-hosted apps, configure the desired host. | -| APP_BIBLIOGRAM | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_RIMGO | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_SCRIBE | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_LIBRARIAN | "" | string | Integration with external self-hosted apps, configure the desired host. | diff --git a/docker/attributes.sh b/docker/attributes.sh index 664b2ce..bbd529a 100755 --- a/docker/attributes.sh +++ b/docker/attributes.sh @@ -34,7 +34,6 @@ export CONFIG_WIKIPEDIA_LANGUAGE=${CONFIG_WIKIPEDIA_LANGUAGE:-${CONFIG_GOOGLE_LA # Supported apps integration configuration. These empty spaces can be set up using free hosts as pointers # A particular example is using the "https://yewtu.be" or a self-hosted host to integrate the invidious app to librex export APP_INVIDIOUS=${APP_INVIDIOUS:-""} -export APP_BIBLIOGRAM=${APP_BIBLIOGRAM:-""} export APP_RIMGO=${APP_RIMGO:-""} export APP_SCRIBE=${APP_SCRIBE:-""} export APP_LIBRARIAN=${APP_LIBRARIAN:-""} diff --git a/docker/php/config.php b/docker/php/config.php index a588745..260376e 100644 --- a/docker/php/config.php +++ b/docker/php/config.php @@ -18,12 +18,6 @@ "original_name" => "YouTube", "original_url" => "youtube.com" ), - "bibliogram" => array( - "instance_url" => "${APP_BIBLIOGRAM}", - "project_url" => "https://git.sr.ht/~cadence/bibliogram-docs/tree/master/docs/Instances.md", - "original_name" => "Instagram", - "original_url" => "instagram.com" - ), "rimgo" => array( "instance_url" => "${APP_RIMGO}", "project_url" => "https://codeberg.org/video-prize-ranch/rimgo#instances", diff --git a/docker/php/php.dockerfile b/docker/php/php.dockerfile index b1b7b82..a2c8022 100644 --- a/docker/php/php.dockerfile +++ b/docker/php/php.dockerfile @@ -22,7 +22,6 @@ ENV CONFIG_BITTORRENT_TRACKERS="&tr=http://nyaa.tracker.wf:7777/announce&tr=udp: # Supported apps integration configuration. These empty spaces can be set up using free hosts as pointers # A particular example is using the "https://yewtu.be" or a self-hosted host to integrate the invidious app to librex ENV APP_INVIDIOUS="" -ENV APP_BIBLIOGRAM="" ENV APP_RIMGO="" ENV APP_SCRIBE="" ENV APP_LIBRARIAN="" diff --git a/misc/tools.php b/misc/tools.php index 191ca4c..96dc08b 100644 --- a/misc/tools.php +++ b/misc/tools.php @@ -30,12 +30,6 @@ else if (!empty($frontends[$frontend]["instance_url"])) $frontend = $frontends[$frontend]["instance_url"]; - if ($original == "instagram.com") - { - if (!strpos($url, "/p/")) - $frontend .= "/u"; - } - if (empty(trim($frontend))) return $url; From 2283a4fee8c2b2e70f6a0d80796f13b4c68e68c3 Mon Sep 17 00:00:00 2001 From: Revvy Date: Sun, 26 Mar 2023 20:10:15 -0400 Subject: [PATCH 04/23] suds => snopes --- config.php.example | 6 ++++++ docker/README.md | 1 + docker/attributes.sh | 1 + docker/php/config.php | 7 +++++++ docker/php/php.dockerfile | 1 + 5 files changed, 16 insertions(+) diff --git a/config.php.example b/config.php.example index 9f9eeb2..2b883a9 100644 --- a/config.php.example +++ b/config.php.example @@ -105,6 +105,12 @@ "project_url" => "https://github.com/httpjamesm/AnonymousOverflow#clearnet-instances", "original_name" => "StackOverflow", "original_url" => "stackoverflow.com" + ), + "suds" => array( + "instance_url" => "", + "project_url" => "https://git.vern.cc/cobra/Suds/src/branch/main/instances.json", + "original_name" => "Suds", + "original_url" => "snopes.com" ) ), diff --git a/docker/README.md b/docker/README.md index f0c5cb9..85d8196 100644 --- a/docker/README.md +++ b/docker/README.md @@ -119,6 +119,7 @@ This docker image was developed with high configurability in mind, so here is th | APP_LIBREMDB | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_BREEZEWIKI | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_ANONYMOUS_OVERFLOW | "" | string | Integration with external self-hosted apps, configure the desired host. | +| APP_SUDS | "" | string | Integration with external self-hosted apps, configure the desired host. |
diff --git a/docker/attributes.sh b/docker/attributes.sh index bbd529a..16ff1c9 100755 --- a/docker/attributes.sh +++ b/docker/attributes.sh @@ -46,6 +46,7 @@ export APP_QUETRE=${APP_QUETRE:-""} export APP_LIBREMDB=${APP_LIBREMDB:-""} export APP_BREEZEWIKI=${APP_BREEZEWIKI:-""} export APP_ANONYMOUS_OVERFLOW=${APP_ANONYMOUS_OVERFLOW:-""} +export APP_SUDS=${APP_SUDS:-""} # GNU/Curl configurations. Leave 'CURLOPT_PROXY' blank whether you don't need to use a proxy for requests # Generally, a proxy is needed when your IP address is blocked by search engines in response to multiple requests within a short time frame. In these cases, it is recommended to use rotating proxies diff --git a/docker/php/config.php b/docker/php/config.php index 260376e..92560c3 100644 --- a/docker/php/config.php +++ b/docker/php/config.php @@ -91,7 +91,14 @@ "project_url" => "https://github.com/httpjamesm/AnonymousOverflow#clearnet-instances", "original_name" => "StackOverflow", "original_url" => "stackoverflow.com" + ), + "suds" => array( + "instance_url" => "${APP_SUDS}", + "project_url" => "https://git.vern.cc/cobra/Suds/src/branch/main/instances.json", + "original_name" => "Suds", + "original_url" => "snopes.com" ) + ), "curl_settings" => array( diff --git a/docker/php/php.dockerfile b/docker/php/php.dockerfile index a2c8022..1878193 100644 --- a/docker/php/php.dockerfile +++ b/docker/php/php.dockerfile @@ -34,6 +34,7 @@ ENV APP_QUETRE="" ENV APP_LIBREMDB="" ENV APP_BREEZEWIKI="" ENV APP_ANONYMOUS_OVERFLOW="" +ENV APP_SUDS="" # GNU/Curl configurations. Leave 'CURLOPT_PROXY' blank whether you don't need to use a proxy for requests # Generally, a proxy is needed when your IP address is blocked by search engines in response to multiple requests within a short time frame. In these cases, it is recommended to use rotating proxies From 92898c06be1c396f562afd50427e22f4cb92c9ee Mon Sep 17 00:00:00 2001 From: Livia Date: Wed, 5 Apr 2023 09:50:56 +0200 Subject: [PATCH 05/23] change tor address since i switched servers and am an idiot --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0ba1c71..2b39244 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ | [librex.revvy.de](https://librex.revvy.de/) | [✅](http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion/) | [✅](http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p/) | 🇨🇦 CA | | [librex.mikata.ru](https://librex.mikata.ru/) | [✅](http://f7ssz7l3biu4fugwctfpcx4txg5yq4gqhrt473ledsuc3ivtd3omniid.onion/) | ❌ | 🇺🇸 US | | [search.milivojevic.in.rs](https://search.milivojevic.in.rs/) | [✅](http://librex2xsek6qnh2i4yufuzqjumfdwtw7io7omgmimpzna6llqudqzyd.onion/) | ❌ | 🇳🇱 NL | -| [search.ahwx.org](https://search.ahwx.org/) | [✅](http://fcnfg6avz45hqzwbneekq57u2mqbnwa7veyvjcc4dndqbatvkjlaj7yd.onion/) | ❌ | 🇳🇱 NL | +| [search.ahwx.org](https://search.ahwx.org/) | [✅](http://cosrpybbddzdfjquer3zfmb2h5avtacnctnbu4gucwocdb42s63gcqqd.onion/) | ❌ | 🇳🇱 NL | | [search.davidovski.xyz](https://search.davidovski.xyz/) | ❌ | ❌ | 🇬🇧 UK | | [search.madreyk.xyz](https://search.madreyk.xyz/) | ❌ | ❌ | 🇩🇪 DE | | [search.pabloferreiro.es](https://search.pabloferreiro.es/) | ❌ | ❌ | 🇩🇪 DE | From 4826071262d35784a994ca783a46f8ea7f6ca13b Mon Sep 17 00:00:00 2001 From: hnhx <49120638+hnhx@users.noreply.github.com> Date: Sat, 8 Apr 2023 09:31:08 +0000 Subject: [PATCH 06/23] removed dead instances, added new ones --- README.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 2b39244..3e66eb7 100644 --- a/README.md +++ b/README.md @@ -13,9 +13,7 @@ | Clearnet | TOR | I2P | Country | |-|-|-|-| -| [search.femboy.hu](https://search.femboy.hu/) | [✅](http://search.cepyxplublbyw2f4axy4pyztfbxmf63lrt2c7uwv6wl4iixz53czload.onion/) | ❌ | 🇭🇺 HU (OFFICIAL INSTANCE) | | [lx.vern.cc](https://lx.vern.cc/) | [✅](http://lx.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion/) | [✅](http://vernziqfqvweijfaacmwazohgpdo2bt2ib2jlupt2pwwu27bhgxq.b32.i2p/) | 🇺🇸 US | -| [search.sesu.cc](https://search.sesu.cc/) | [✅](http://search.swxoebbpeqiiixyhbuh3vbw53pdrmtbiaj2sqveol6kkn5rpapfi4aad.onion/) | [✅](http://lqbchqljxiwl3bbjt4vqe76luovk5ly6khqhg7mt5qcqfn6e4sbq.b32.i2p/) | 🇨🇱 CL | | [librex.zzls.xyz](https://librex.zzls.xyz/) | [✅](http://librex.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion/) | [✅](http://7huurwog32tny663wkglrhozfoyqyqmsuxjbd7dtudccx44awjda.b32.i2p) | 🇨🇱 CL | | [librex.revvy.de](https://librex.revvy.de/) | [✅](http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion/) | [✅](http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p/) | 🇨🇦 CA | | [librex.mikata.ru](https://librex.mikata.ru/) | [✅](http://f7ssz7l3biu4fugwctfpcx4txg5yq4gqhrt473ledsuc3ivtd3omniid.onion/) | ❌ | 🇺🇸 US | @@ -24,17 +22,17 @@ | [search.davidovski.xyz](https://search.davidovski.xyz/) | ❌ | ❌ | 🇬🇧 UK | | [search.madreyk.xyz](https://search.madreyk.xyz/) | ❌ | ❌ | 🇩🇪 DE | | [search.pabloferreiro.es](https://search.pabloferreiro.es/) | ❌ | ❌ | 🇩🇪 DE | -| [buscar.weblibre.org](https://buscar.weblibre.org/) | ❌ | ❌ | 🇨🇱 CL | | [librex.pufe.org](https://librex.pufe.org/) | ❌ | ❌ | :new_zealand: NZ | | [librex.ratakor.com](https://librex.ratakor.com/) | ❌ | ❌ | 🇫🇷 FR | | [search.tildevarsh.in](https://search.tildevarsh.in/) | ❌ | ❌ | 🇮🇳 IN | | [librex.myroware.eu](https://librex.myroware.eu/) | ❌ | ❌ | 🇩🇪 DE | -| [lx.drain.win](https://lx.drain.win/) | ❌ | ❌ | 🇸🇬 SG | | [librex.bloatcat.tk](https://librex.bloatcat.tk/) | ❌ | ❌ | 🇮🇸 IS | | [librex.retro-hax.net](https://librex.retro-hax.net/) | ❌ | ❌ | 🇩🇪 DE | | [search.funami.tech](https://search.funami.tech/) | ❌ | ❌ | 🇰🇷 KR | | [search.zeroish.xyz](https://search.zeroish.xyz/) | ❌| ❌ | 🇺🇸 US | | [librex.baczek.me](https://librex.baczek.me/) | ❌| ❌ | 🇵🇱 PL | +| [librex.yogeshlamichhane.com.np](https://librex.yogeshlamichhane.com.np/) | ❌| ❌ | 🇺🇸 US | +| [search.spaceint.fr](https://search.spaceint.fr/) | ❌ | ❌ | 🇩🇪 DE |
### Thanks rms From 52ae847748666c04e7b5a26e70b6a8d0692e2891 Mon Sep 17 00:00:00 2001 From: hnhx <49120638+hnhx@users.noreply.github.com> Date: Sat, 8 Apr 2023 09:35:49 +0000 Subject: [PATCH 07/23] updated the instances in the json file as well --- instances.json | 38 +++++++++++++------------------------- 1 file changed, 13 insertions(+), 25 deletions(-) diff --git a/instances.json b/instances.json index edc8497..5151241 100644 --- a/instances.json +++ b/instances.json @@ -1,23 +1,11 @@ { "instances": [ - { - "clearnet": "https://search.femboy.hu/", - "tor": "http://search.cepyxplublbyw2f4axy4pyztfbxmf63lrt2c7uwv6wl4iixz53czload.onion/", - "i2p": null, - "country": "HU" - }, { "clearnet": "https://lx.vern.cc/", "tor": "http://lx.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion/", "i2p": "http://vernziqfqvweijfaacmwazohgpdo2bt2ib2jlupt2pwwu27bhgxq.b32.i2p/", "country": "US" }, - { - "clearnet": "https://search.sesu.cc/", - "tor": "http://search.swxoebbpeqiiixyhbuh3vbw53pdrmtbiaj2sqveol6kkn5rpapfi4aad.onion/", - "i2p": "http://lqbchqljxiwl3bbjt4vqe76luovk5ly6khqhg7mt5qcqfn6e4sbq.b32.i2p/", - "country": "CL" - }, { "clearnet": "https://librex.zzls.xyz/", "tor": "http://librex.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion/", @@ -38,7 +26,7 @@ }, { "clearnet": "https://search.ahwx.org/", - "tor": "http://fcnfg6avz45hqzwbneekq57u2mqbnwa7veyvjcc4dndqbatvkjlaj7yd.onion/", + "tor": "http://cosrpybbddzdfjquer3zfmb2h5avtacnctnbu4gucwocdb42s63gcqqd.onion/", "i2p": null, "country": "NL" }, @@ -60,12 +48,6 @@ "i2p": null, "country": "DE" }, - { - "clearnet": "https://buscar.weblibre.org/", - "tor": null, - "i2p": null, - "country": "CL" - }, { "clearnet": "https://librex.pufe.org/", "tor": null, @@ -96,12 +78,6 @@ "i2p": null, "country": "DE" }, - { - "clearnet": "https://lx.drain.win/", - "tor": null, - "i2p": null, - "country": "SG" - }, { "clearnet": "https://librex.bloatcat.tk/", "tor": null, @@ -131,6 +107,18 @@ "tor": null, "i2p": null, "country": "PL" + }, + { + "clearnet": "https://librex.yogeshlamichhane.com.np/", + "tor": null, + "i2p": null, + "country": "US" + }, + { + "clearnet": "https://search.spaceint.fr/", + "tor": null, + "i2p": null, + "country": "DE" } ] } From 9e2421400037497321004833e6a63b52e2852810 Mon Sep 17 00:00:00 2001 From: rafalohaki Date: Sun, 9 Apr 2023 00:52:38 +0200 Subject: [PATCH 08/23] fix librex image pull access fixed: pull access denied for librex --- docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose.yml b/docker-compose.yml index 5ce8593..c9224aa 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,7 +1,7 @@ version: "2.1" services: librex: - image: librex:latest + image: librex/librex:latest container_name: librex network_mode: bridge ports: From c13228e24080280df97b5ea1b69ba1b07bc4d026 Mon Sep 17 00:00:00 2001 From: rafalohaki Date: Sun, 9 Apr 2023 01:19:53 +0200 Subject: [PATCH 09/23] Update sukebei.php textContent, XPath expression fix --- engines/bittorrent/sukebei.php | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/engines/bittorrent/sukebei.php b/engines/bittorrent/sukebei.php index 65fd177..023cf6c 100644 --- a/engines/bittorrent/sukebei.php +++ b/engines/bittorrent/sukebei.php @@ -9,11 +9,21 @@ foreach($xpath->query("//tbody/tr") as $result) { - $name = $xpath->evaluate(".//td[@colspan='2']//a[not(contains(@class, 'comments'))]/@title", $result)[0]->textContent; + $name_node = $xpath->evaluate(".//td[@colspan='2']//a[not(contains(@class, 'comments'))]/@title", $result); + if ($name_node->length > 0) { + $name = $name_node[0]->textContent; + } else { + $name = ""; + } $centered = $xpath->evaluate(".//td[@class='text-center']", $result); - $magnet = $xpath->evaluate(".//a[2]/@href", $centered[0])[0]->textContent; - $magnet_without_tracker = explode("&tr=", $magnet)[0]; - $magnet = $magnet_without_tracker . $config->bittorent_trackers; + $magnet_node = $xpath->evaluate(".//a[2]/@href", $centered[0]); + if ($magnet_node->length > 0) { + $magnet = $magnet_node[0]->textContent; + $magnet_without_tracker = explode("&tr=", $magnet)[0]; + $magnet = $magnet_without_tracker . $config->bittorent_trackers; + } else { + $magnet = ""; + } $size = $centered[1]->textContent; $seeders = $centered[3]->textContent; $leechers = $centered[4]->textContent; From f34549b97290c94c6269e4e60fed2ff4cf78984b Mon Sep 17 00:00:00 2001 From: rafalohaki Date: Sun, 9 Apr 2023 01:24:39 +0200 Subject: [PATCH 10/23] Update sukebei.php Modified the get_sukebei_results() function to handle cases where the name and magnet nodes are null or do not exist. Added conditional statements to check if the name and magnet nodes exist before attempting to access their properties, in order to prevent null errors and warnings. Added empty string as the default value for name and magnet variables in case their corresponding nodes are null or do not exist. Removed the use of deprecated functions explode() and htmlspecialchars() in the code. No longer accessing the textContent property of DOMXPath::evaluate(). --- engines/bittorrent/sukebei.php | 1 - 1 file changed, 1 deletion(-) diff --git a/engines/bittorrent/sukebei.php b/engines/bittorrent/sukebei.php index 023cf6c..61485cc 100644 --- a/engines/bittorrent/sukebei.php +++ b/engines/bittorrent/sukebei.php @@ -39,7 +39,6 @@ ) ); } - return $results; } ?> From b52b2aa4dae916ce35619ad811c86a1a893aca61 Mon Sep 17 00:00:00 2001 From: Revvy Date: Sun, 9 Apr 2023 18:37:22 -0400 Subject: [PATCH 11/23] fix original_name --- config.php.example | 2 +- docker/php/config.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config.php.example b/config.php.example index 2b883a9..58c17b9 100644 --- a/config.php.example +++ b/config.php.example @@ -109,7 +109,7 @@ "suds" => array( "instance_url" => "", "project_url" => "https://git.vern.cc/cobra/Suds/src/branch/main/instances.json", - "original_name" => "Suds", + "original_name" => "Snopes", "original_url" => "snopes.com" ) ), diff --git a/docker/php/config.php b/docker/php/config.php index 92560c3..e866196 100644 --- a/docker/php/config.php +++ b/docker/php/config.php @@ -95,7 +95,7 @@ "suds" => array( "instance_url" => "${APP_SUDS}", "project_url" => "https://git.vern.cc/cobra/Suds/src/branch/main/instances.json", - "original_name" => "Suds", + "original_name" => "Snopes", "original_url" => "snopes.com" ) From ef32e900eb2c4edbe8c925dd21f47c877f9fce08 Mon Sep 17 00:00:00 2001 From: monster energy <69584313+drinkmonster@users.noreply.github.com> Date: Thu, 13 Apr 2023 09:56:47 +0200 Subject: [PATCH 12/23] added my instance --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 3e66eb7..088bd75 100644 --- a/README.md +++ b/README.md @@ -33,6 +33,7 @@ | [librex.baczek.me](https://librex.baczek.me/) | ❌| ❌ | 🇵🇱 PL | | [librex.yogeshlamichhane.com.np](https://librex.yogeshlamichhane.com.np/) | ❌| ❌ | 🇺🇸 US | | [search.spaceint.fr](https://search.spaceint.fr/) | ❌ | ❌ | 🇩🇪 DE | +| [lx.benike.monster](https://lx.benike.monster/) | ❌ | ❌ | 🇩🇪 DE |
### Thanks rms From 96f47b9600c82724d6140e59d10f17b4f3d66383 Mon Sep 17 00:00:00 2001 From: monster energy <69584313+drinkmonster@users.noreply.github.com> Date: Thu, 13 Apr 2023 09:59:05 +0200 Subject: [PATCH 13/23] also added to instances.json --- instances.json | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/instances.json b/instances.json index 5151241..f6e7c8b 100644 --- a/instances.json +++ b/instances.json @@ -119,6 +119,12 @@ "tor": null, "i2p": null, "country": "DE" + }, + { + "clearnet": "https://lx.benike.monster/", + "tor": null, + "i2p": null, + "country": "DE" } ] } From 50467f2a9c6240c351079c8ca79d670e18afeaca Mon Sep 17 00:00:00 2001 From: Revvy Date: Sat, 22 Apr 2023 17:07:25 -0400 Subject: [PATCH 14/23] gist support with gothub --- misc/tools.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/misc/tools.php b/misc/tools.php index 96dc08b..19f36cb 100644 --- a/misc/tools.php +++ b/misc/tools.php @@ -51,6 +51,11 @@ $url = $frontend . "/" . $wiki_name . explode($original, $url)[1]; } } + else if (strpos($url, "gist.github.com") !== false) + { + $gist_path = explode("gist.github.com", $url)[1]; + $url = $frontend . "/gist" . $gist_path; + } else { $url = $frontend . explode($original, $url)[1]; From 398961cd3dce1fb0358866b20df3d4c300e0a210 Mon Sep 17 00:00:00 2001 From: Revvy Date: Mon, 24 Apr 2023 19:19:46 -0400 Subject: [PATCH 15/23] goodreads => biblioreads --- config.php.example | 6 ++++++ docker/README.md | 1 + docker/attributes.sh | 1 + docker/php/config.php | 7 ++++++- docker/php/php.dockerfile | 2 ++ 5 files changed, 16 insertions(+), 1 deletion(-) diff --git a/config.php.example b/config.php.example index 58c17b9..d53280e 100644 --- a/config.php.example +++ b/config.php.example @@ -111,6 +111,12 @@ "project_url" => "https://git.vern.cc/cobra/Suds/src/branch/main/instances.json", "original_name" => "Snopes", "original_url" => "snopes.com" + ), + "biblioreads" => array( + "instance_url" => "", + "project_url" => "https://github.com/nesaku/BiblioReads#instances", + "original_name" => "Goodreads", + "original_url" => "goodreads.com" ) ), diff --git a/docker/README.md b/docker/README.md index 85d8196..04f2088 100644 --- a/docker/README.md +++ b/docker/README.md @@ -120,6 +120,7 @@ This docker image was developed with high configurability in mind, so here is th | APP_BREEZEWIKI | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_ANONYMOUS_OVERFLOW | "" | string | Integration with external self-hosted apps, configure the desired host. | | APP_SUDS | "" | string | Integration with external self-hosted apps, configure the desired host. | +| APP_BIBLIOREADS | "" | string | Integration with external self-hosted apps, configure the desired host. |
diff --git a/docker/attributes.sh b/docker/attributes.sh index 16ff1c9..26ca7a7 100755 --- a/docker/attributes.sh +++ b/docker/attributes.sh @@ -47,6 +47,7 @@ export APP_LIBREMDB=${APP_LIBREMDB:-""} export APP_BREEZEWIKI=${APP_BREEZEWIKI:-""} export APP_ANONYMOUS_OVERFLOW=${APP_ANONYMOUS_OVERFLOW:-""} export APP_SUDS=${APP_SUDS:-""} +export APP_BIBLIOREADS=${APP_BIBLIOREADS:-""} # GNU/Curl configurations. Leave 'CURLOPT_PROXY' blank whether you don't need to use a proxy for requests # Generally, a proxy is needed when your IP address is blocked by search engines in response to multiple requests within a short time frame. In these cases, it is recommended to use rotating proxies diff --git a/docker/php/config.php b/docker/php/config.php index e866196..3d0d8ea 100644 --- a/docker/php/config.php +++ b/docker/php/config.php @@ -97,8 +97,13 @@ "project_url" => "https://git.vern.cc/cobra/Suds/src/branch/main/instances.json", "original_name" => "Snopes", "original_url" => "snopes.com" + ), + "biblioreads" => array( + "instance_url" => "${APP_BIBLIOREADS}", + "project_url" => "https://github.com/nesaku/BiblioReads#instances", + "original_name" => "Goodreads", + "original_url" => "goodreads.com" ) - ), "curl_settings" => array( diff --git a/docker/php/php.dockerfile b/docker/php/php.dockerfile index 1878193..3252e0e 100644 --- a/docker/php/php.dockerfile +++ b/docker/php/php.dockerfile @@ -35,6 +35,8 @@ ENV APP_LIBREMDB="" ENV APP_BREEZEWIKI="" ENV APP_ANONYMOUS_OVERFLOW="" ENV APP_SUDS="" +ENV APP_BIBLIOREADS="" + # GNU/Curl configurations. Leave 'CURLOPT_PROXY' blank whether you don't need to use a proxy for requests # Generally, a proxy is needed when your IP address is blocked by search engines in response to multiple requests within a short time frame. In these cases, it is recommended to use rotating proxies From 2b33116fe06f3f6c8de9c5f034876f3de904e96c Mon Sep 17 00:00:00 2001 From: Nicola Guerrera Date: Sun, 30 Apr 2023 14:56:55 +0200 Subject: [PATCH 16/23] Make openserach.xml location relative --- misc/header.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/misc/header.php b/misc/header.php index 10a2435..36da4bf 100644 --- a/misc/header.php +++ b/misc/header.php @@ -6,7 +6,7 @@ - + Date: Sun, 30 Apr 2023 18:16:58 +0200 Subject: [PATCH 17/23] Added two new themes: ubuntu and tokyo_night --- settings.php | 4 +++- static/css/tokyo_night.css | 26 ++++++++++++++++++++++++++ static/css/ubuntu.css | 24 ++++++++++++++++++++++++ 3 files changed, 53 insertions(+), 1 deletion(-) create mode 100644 static/css/tokyo_night.css create mode 100644 static/css/ubuntu.css diff --git a/settings.php b/settings.php index bca23e1..fa41f3d 100644 --- a/settings.php +++ b/settings.php @@ -62,7 +62,9 @@ - "; + + + "; if (isset($_COOKIE["theme"])) { diff --git a/static/css/tokyo_night.css b/static/css/tokyo_night.css new file mode 100644 index 0000000..ccafda7 --- /dev/null +++ b/static/css/tokyo_night.css @@ -0,0 +1,26 @@ +:root { + --main-bg: #24283b; + --main-fg: #cfc9c2; + + --result-link-fg: #bb9af7; + --result-fg: #a2a08e; + + --button-bg: #343b58; + + --special-result-border: border 0; + --special-text-background: #1b1b18; + --special-text-color: #f2efd3; + + --search-container-text-color: #f2efd3; + --search-container-background-color: #565f89; + --search-container-background-border: #bb9af7; + + --search-form-background-color: #1a1b26; + + --border: #565f89; + + --footer-fg: #f2efd3; + --footer-bg: #1a1b26; + + color-scheme: dark; +} diff --git a/static/css/ubuntu.css b/static/css/ubuntu.css new file mode 100644 index 0000000..cd96da5 --- /dev/null +++ b/static/css/ubuntu.css @@ -0,0 +1,24 @@ +:root { + --main-bg: #2C001E; + --main-fg: #FFFFFF; + + --result-link-fg: #84de32; + --result-fg: #a2a08e; + + --button-bg: #5E2750; + + --special-result-border: border 0; + --special-text-background: #1b1b18; + --special-text-color: #f2efd3; + + --search-container-text-color: #f2efd3; + --search-container-background-color: #77216F; + --search-container-background-border: #E95420; + + --search-form-background-color: #333333; + + --border: #77216F; + + --footer-fg: #f2efd3; + --footer-bg: #5E2750; +} From e29fe840780451513f2b0ba7616fb2a67ab733dc Mon Sep 17 00:00:00 2001 From: Hukasx0 Date: Sun, 30 Apr 2023 21:31:40 +0200 Subject: [PATCH 18/23] Colors have been slightly modified --- static/css/tokyo_night.css | 4 ++-- static/css/ubuntu.css | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/static/css/tokyo_night.css b/static/css/tokyo_night.css index ccafda7..bd97a92 100644 --- a/static/css/tokyo_night.css +++ b/static/css/tokyo_night.css @@ -8,8 +8,8 @@ --button-bg: #343b58; --special-result-border: border 0; - --special-text-background: #1b1b18; - --special-text-color: #f2efd3; + --special-text-background: #1a1b26; + --special-text-color: #c0caf5; --search-container-text-color: #f2efd3; --search-container-background-color: #565f89; diff --git a/static/css/ubuntu.css b/static/css/ubuntu.css index cd96da5..19b5147 100644 --- a/static/css/ubuntu.css +++ b/static/css/ubuntu.css @@ -8,8 +8,8 @@ --button-bg: #5E2750; --special-result-border: border 0; - --special-text-background: #1b1b18; - --special-text-color: #f2efd3; + --special-text-background: #333333; + --special-text-color: #FFFFFF; --search-container-text-color: #f2efd3; --search-container-background-color: #77216F; @@ -21,4 +21,6 @@ --footer-fg: #f2efd3; --footer-bg: #5E2750; + + color-scheme: dark; } From e3663f996ed37e05be485287aa9ca0dd55aa2295 Mon Sep 17 00:00:00 2001 From: hnhx <49120638+hnhx@users.noreply.github.com> Date: Mon, 1 May 2023 08:14:04 +0000 Subject: [PATCH 19/23] removed a dead instance --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 088bd75..8fc909c 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,6 @@ | Clearnet | TOR | I2P | Country | |-|-|-|-| -| [lx.vern.cc](https://lx.vern.cc/) | [✅](http://lx.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion/) | [✅](http://vernziqfqvweijfaacmwazohgpdo2bt2ib2jlupt2pwwu27bhgxq.b32.i2p/) | 🇺🇸 US | | [librex.zzls.xyz](https://librex.zzls.xyz/) | [✅](http://librex.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion/) | [✅](http://7huurwog32tny663wkglrhozfoyqyqmsuxjbd7dtudccx44awjda.b32.i2p) | 🇨🇱 CL | | [librex.revvy.de](https://librex.revvy.de/) | [✅](http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion/) | [✅](http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p/) | 🇨🇦 CA | | [librex.mikata.ru](https://librex.mikata.ru/) | [✅](http://f7ssz7l3biu4fugwctfpcx4txg5yq4gqhrt473ledsuc3ivtd3omniid.onion/) | ❌ | 🇺🇸 US | From 1346e9fcc1c8cdb9997585ac990c732153df9726 Mon Sep 17 00:00:00 2001 From: hnhx <49120638+hnhx@users.noreply.github.com> Date: Mon, 1 May 2023 08:15:24 +0000 Subject: [PATCH 20/23] removed a dead instance from the json as well --- instances.json | 6 ------ 1 file changed, 6 deletions(-) diff --git a/instances.json b/instances.json index f6e7c8b..b067125 100644 --- a/instances.json +++ b/instances.json @@ -1,11 +1,5 @@ { "instances": [ - { - "clearnet": "https://lx.vern.cc/", - "tor": "http://lx.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion/", - "i2p": "http://vernziqfqvweijfaacmwazohgpdo2bt2ib2jlupt2pwwu27bhgxq.b32.i2p/", - "country": "US" - }, { "clearnet": "https://librex.zzls.xyz/", "tor": "http://librex.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion/", From 870ef39b8c368464b6f5a0d1c05175f4c6bdf931 Mon Sep 17 00:00:00 2001 From: Hubert Kasperek <82332291+Hukasx0@users.noreply.github.com> Date: Tue, 2 May 2023 19:07:16 +0200 Subject: [PATCH 21/23] Fixed 'no space between attributes' Found by the HTML validator --- search.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/search.php b/search.php index ad5ea74..cca10c3 100644 --- a/search.php +++ b/search.php @@ -48,7 +48,7 @@ continue; } - echo "\""" . ucfirst($category) . ""; + echo "\""" . ucfirst($category) . ""; } ?>
From 88df13340ae2e5569b703a4da363d2b3d558a0b3 Mon Sep 17 00:00:00 2001 From: Hubert Kasperek <82332291+Hukasx0@users.noreply.github.com> Date: Tue, 2 May 2023 19:40:30 +0200 Subject: [PATCH 22/23] Changed space placement to remove unnecessary space when condition is not met --- search.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/search.php b/search.php index cca10c3..afeb641 100644 --- a/search.php +++ b/search.php @@ -48,7 +48,7 @@ continue; } - echo "\""" . ucfirst($category) . ""; + echo "\""" . ucfirst($category) . ""; } ?> From 972d69006462f9da0d2098ea9280a75bd88c6457 Mon Sep 17 00:00:00 2001 From: Revvy Date: Wed, 3 May 2023 20:33:59 -0400 Subject: [PATCH 23/23] change clearnet domain for my instance --- README.md | 2 +- instances.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8fc909c..9a88f7f 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ | Clearnet | TOR | I2P | Country | |-|-|-|-| | [librex.zzls.xyz](https://librex.zzls.xyz/) | [✅](http://librex.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion/) | [✅](http://7huurwog32tny663wkglrhozfoyqyqmsuxjbd7dtudccx44awjda.b32.i2p) | 🇨🇱 CL | -| [librex.revvy.de](https://librex.revvy.de/) | [✅](http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion/) | [✅](http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p/) | 🇨🇦 CA | +| [librex.me](https://librex.me/) | [✅](http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion/) | [✅](http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p/) | 🇨🇦 CA | | [librex.mikata.ru](https://librex.mikata.ru/) | [✅](http://f7ssz7l3biu4fugwctfpcx4txg5yq4gqhrt473ledsuc3ivtd3omniid.onion/) | ❌ | 🇺🇸 US | | [search.milivojevic.in.rs](https://search.milivojevic.in.rs/) | [✅](http://librex2xsek6qnh2i4yufuzqjumfdwtw7io7omgmimpzna6llqudqzyd.onion/) | ❌ | 🇳🇱 NL | | [search.ahwx.org](https://search.ahwx.org/) | [✅](http://cosrpybbddzdfjquer3zfmb2h5avtacnctnbu4gucwocdb42s63gcqqd.onion/) | ❌ | 🇳🇱 NL | diff --git a/instances.json b/instances.json index b067125..e710af1 100644 --- a/instances.json +++ b/instances.json @@ -7,7 +7,7 @@ "country": "CL" }, { - "clearnet": "https://librex.revvy.de/", + "clearnet": "https://librex.me/", "tor": "http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion/", "i2p": "http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p/", "country": "CA"