summaryrefslogtreecommitdiffstats
path: root/rust/wolfree_libredirect_patch
diff options
context:
space:
mode:
authorname <email@example.com>2023-09-27 13:34:23 +0200
committername <email@example.com>2023-09-27 13:34:23 +0200
commit72d8b4e6bee0ffac79e96dd649a9da2adb86b507 (patch)
tree8d1f37e5d88a598675b1a65128c35323c99825f5 /rust/wolfree_libredirect_patch
parentMerge pull request 'Please consider adding my instance' (#2) from superprivacy/wolfree-dockerfile:main into main (diff)
downloadwolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.tar
wolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.tar.gz
wolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.tar.bz2
wolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.tar.lz
wolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.tar.xz
wolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.tar.zst
wolfree-dockerfile-72d8b4e6bee0ffac79e96dd649a9da2adb86b507.zip
Diffstat (limited to '')
-rw-r--r--rust/wolfree_libredirect_patch/Cargo.toml21
-rw-r--r--rust/wolfree_libredirect_patch/src/body.md68
-rw-r--r--rust/wolfree_libredirect_patch/src/head.html43
-rw-r--r--rust/wolfree_libredirect_patch/src/main.rs95
-rw-r--r--rust/wolfree_patch_libredirect/src/docusaurus/static/instances.json (renamed from rust/wolfree_libredirect_patch/src/instances.json)0
5 files changed, 0 insertions, 227 deletions
diff --git a/rust/wolfree_libredirect_patch/Cargo.toml b/rust/wolfree_libredirect_patch/Cargo.toml
deleted file mode 100644
index 5b587d5..0000000
--- a/rust/wolfree_libredirect_patch/Cargo.toml
+++ /dev/null
@@ -1,21 +0,0 @@
-# SPDX-License-Identifier: AGPL-3.0-or-later
-# This file is part of Wolfree.
-# This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
-
-[package]
-name = "wolfree_libredirect_patch"
-version = "23.7.31"
-edition = "2021"
-
-authors = ["See the commit history of the Git repositories: <https://try.gitea.io/wolfree>"]
-description = "The Rust crate provides lightweight wrappers around the `fs::write` and `fs::remove_dir_all` functions from the standard library's `fs` module."
-license = "AGPL-3.0-or-later"
-repository = "https://try.gitea.io/wolfree"
-readme = "README.md"
-keywords = ["rust", "wrapper", "write", "remove", "file"]
-categories = ["command-line-utilities", "development-tools::build-utils", "web-programming"]
-
-# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
-
-[dependencies]
-markdown = "1.0.0-alpha"
diff --git a/rust/wolfree_libredirect_patch/src/body.md b/rust/wolfree_libredirect_patch/src/body.md
deleted file mode 100644
index 69ccfc1..0000000
--- a/rust/wolfree_libredirect_patch/src/body.md
+++ /dev/null
@@ -1,68 +0,0 @@
-# Paywall-Respecting Instances: Wolfree instances that do not bypass any paywall
-
-Welcome to Paywall-Respecting Instances, where we provide Wolfree instances that **do not bypass any paywall**.
-
-## The Problem with Other Wolfree Instances
-
-Most other Wolfree instances can bypass paywalls, which raises concerns about Microsoft GitHub's [DMCA Takedown Policy](https://docs.github.com/en/site-policy/content-removal-policies/dmca-takedown-policy).
-
-Unfortunately, this means that developers of [LibRedirect](https://libredirect.github.io/) cannot redirect users to such instances.
-
-To learn more about this issue, please refer to [issue #425](https://github.com/libredirect/browser_extension/issues/425) on Microsoft GitHub.
-
-## The Solution: Paywall-Respecting Instances
-
-Unlike other Wolfree instances, Paywall-Respecting Instances prioritize ethical practices and **do not bypass any paywall**. So developers of LibRedirect can confidently redirect their users to Paywall-Respecting Instances.
-
-## Instance List
-
-Here are some Paywall-Respecting Instances you can access:
-
-1. https://gqq.gitlab.io/
-2. https://jqq.gitlab.io/
-3. https://rqq.gitlab.io/
-4. https://sqq.gitlab.io/
-5. https://uqq.gitlab.io/
-
-JSON: [instances.json](/instances.json)
-
-## Source Code
-
-Paywall-Respecting Instances is free and open-source software. You can access and download its source code from the following websites:
-
-1. https://try.gitea.io/wolfree
-2. https://codeberg.org/wolfree
-3. https://git.disroot.org/wolfree
-4. https://next.forgejo.org/wolfree
-5. https://git.kiwifarms.net/wolfree
-6. http://it7otdanqu7ktntxzm427cba6i53w6wlanlh23v5i3siqmos47pzhvyd.onion/wolfree
-
-SPDX-License-Identifier: AGPL-3.0-or-later
-
-This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
-
-## How it Works
-
-1. Install [LibRedirect](https://libredirect.github.io/) on your web browser.
-2. LibRedirect automatically redirects you from Wolfram to our instances, safeguarding your privacy.
-3. Enjoy accessing Wolfree instances that uphold ethical practices and **do not bypass any paywall**.
-
-## Key Features
-
-### Compliance with Microsoft GitHub
-
-Paywall-Respecting Instances **do not bypass any paywall**, empowering LibRedirect developers with the confidence to redirect users to our instances.
-
-### Protect Your Privacy
-
-Once you install LibRedirect on your web browser, LibRedirect automatically redirects you from Wolfram to our instances, securing your digital privacy.
-
-### Ethical Practices
-
-By accessing our instances, you actively promote ethical practices and support the work of content creators.
-
-## Get Started Now!
-
-Install LibRedirect to access Paywall-Respecting Instances. Enjoy Wolfree instances that **do not bypass any paywall**.
-
-- [Install LibRedirect](https://libredirect.github.io/)
diff --git a/rust/wolfree_libredirect_patch/src/head.html b/rust/wolfree_libredirect_patch/src/head.html
deleted file mode 100644
index d67963c..0000000
--- a/rust/wolfree_libredirect_patch/src/head.html
+++ /dev/null
@@ -1,43 +0,0 @@
-<!DOCTYPE html>
-<html lang="en">
-
-<head>
- <meta charset="utf-8" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0" />
- <meta name="description"
- content="With our seamless integration with LibRedirect, a web browser extension that protects your digital privacy, you can ensure that your access to Wolfree instances preserves your privacy and complies with Microsoft GitHub's DMCA Takedown Policy." />
- <title>
- Wolfree instances that do not bypass any paywall | Paywall-Respecting Instances
- </title>
- <style>
- html {
- margin: 1rem;
- font-family: sans-serif;
- }
-
- body {
- max-width: 30rem;
- margin: 5rem auto;
- }
-
- h1,
- h2 {
- margin-top: 5rem;
- line-height: 1.5;
- }
-
- p,
- li {
- line-height: 2;
- }
-
- a {
- text-decoration: none;
- word-wrap: break-word;
- }
- </style>
- <link rel="icon" href="data:," />
-</head>
-
-</html>
-<!-- SPDX-License-Identifier: AGPL-3.0-or-later --> \ No newline at end of file
diff --git a/rust/wolfree_libredirect_patch/src/main.rs b/rust/wolfree_libredirect_patch/src/main.rs
deleted file mode 100644
index 65f1b93..0000000
--- a/rust/wolfree_libredirect_patch/src/main.rs
+++ /dev/null
@@ -1,95 +0,0 @@
-//! The Rust crate provides lightweight wrappers around the `fs::write` and `fs::remove_dir_all` functions from the standard library's `fs` module.
-//! The crate is designed to simplify file writing and directory removal operations by encapsulating the error handling logic and providing a more convenient interface.
-//! It is particularly useful for tasks that involve writing multiple files or removing directories with their contents.
-
-#![allow(clippy::blanket_clippy_restriction_lints)]
-#![allow(clippy::exit)]
-#![allow(clippy::print_stderr)]
-#![allow(clippy::implicit_return)]
-
-/* SPDX-License-Identifier: AGPL-3.0-or-later
- * This file is part of Wolfree.
- * This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
- */
-
-use markdown::to_html_with_options;
-use markdown::Options;
-use std::fs;
-
-/// A lightweight wrapper around `fs::write`.
-fn wolfree_write(file_path: &str, contents: &str) {
- match fs::write(file_path, contents) {
- Ok(_) => (),
- Err(err) => {
- eprintln!("Error: {err}",);
- std::process::exit(1);
- }
- };
-}
-
-/// A lightweight wrapper around `fs::remove_dir_all`.
-fn wolfree_remove_dir_all(dir_path: &str) {
- match fs::remove_dir_all(dir_path) {
- Ok(_) => (),
- Err(err) => {
- eprintln!("Error: {err}",);
- std::process::exit(1);
- }
- };
-}
-
-/// A lightweight wrapper around `markdown::to_html_with_options`.
-fn wolfree_to_html_with_options(value: &str) -> String {
- match to_html_with_options(value, &Options::gfm()) {
- Ok(result) => result,
- Err(err) => {
- eprintln!("Error: {err}",);
- std::process::exit(1);
- }
- }
-}
-
-/// Entry point of the program.
-fn main() {
- wolfree_write(
- "./docusaurus/build/ajax/libs/wolfree/23.7.8/js/Entrypoint.js",
- "export default () => {}",
- );
- wolfree_write(
- "./docusaurus/build/index.html",
- &format!(
- "{}{}",
- include_str!("head.html"),
- wolfree_to_html_with_options(include_str!("body.md")),
- ),
- );
- wolfree_write(
- "./docusaurus/build/instances.json",
- include_str!("instances.json"),
- );
- wolfree_write(
- "./docusaurus/build/404.html",
- "<script>location='/'</script>",
- );
- wolfree_write(
- "./docusaurus/build/acknowledgment/index.html",
- "<script>location='/'</script>",
- );
- wolfree_write(
- "./docusaurus/build/community/index.html",
- "<script>location='/'</script>",
- );
- wolfree_write(
- "./docusaurus/build/dmca/index.html",
- "<script>location='/'</script>",
- );
- wolfree_write(
- "./docusaurus/build/mirror/index.html",
- "<script>location='/'</script>",
- );
- wolfree_write(
- "./docusaurus/build/source/index.html",
- "<script>location='/'</script>",
- );
- wolfree_remove_dir_all("./docusaurus/build/assets/");
-}
diff --git a/rust/wolfree_libredirect_patch/src/instances.json b/rust/wolfree_patch_libredirect/src/docusaurus/static/instances.json
index 8cdd008..8cdd008 100644
--- a/rust/wolfree_libredirect_patch/src/instances.json
+++ b/rust/wolfree_patch_libredirect/src/docusaurus/static/instances.json