commit 9c6021c632dac153a9681a3667d847fd184dcdf1
parent bfb57788e0c278724fd5af150cdf4df277b81748
Author: Yuval Langer <yuval.langer@gmail.com>
Date: Mon, 26 Aug 2024 22:06:21 +0300
Change usage text.
Diffstat:
2 files changed, 9 insertions(+), 14 deletions(-)
diff --git a/README.md b/README.md
@@ -4,15 +4,11 @@ Replace taboo things in your kill using predefined rules.
## Usage:
-Let's say you have the text "AMAZING VIDEO! The quick brown fox
-jumped over the lazy fox! https://youtu.be/f2d6q2oUJeY", but your
-anti-corpo paranoid friends would ban you from the channel you all
-hang out in if you do not use something like Invidious to link Youtube
-videos.
+Let's say you have the text "https://twitter.com/Nadav_Eyal/status/1809975194926055629" and would rather have something like "https://nitter.poast.org/Nadav_Eyal/status/1809975194926055629" instead.
A possible solution is to:
-0. Set up `detubifier-regexp-replacement-pairs'.
+0. Set up `detubifier-regexp-replacement-pairs` using the customize-variable command.
1. Mark that text.
2. Kill it.
3. Run `detubifier-regexp-replacement-pairs'.
diff --git a/detubifier.el b/detubifier.el
@@ -24,13 +24,11 @@
;; Usage:
;;
-;; Let's say you have the text "AMAZING VIDEO! The quick brown fox
-;; jumped over the lazy fox! https://youtu.be/f2d6q2oUJeY", but your
-;; anti-corpo paranoid friends would ban you from the channel you all
-;; hang out in if you do not use something like Invidious to link
-;; Youtube videos.
-;;
-;; A possible solution is to:
+;; Let's say you have the text
+;; "https://twitter.com/Nadav_Eyal/status/1809975194926055629" and
+;; would rather have something like
+;; "https://nitter.poast.org/Nadav_Eyal/status/1809975194926055629"
+;; instead. A possible solution is to:
;;
;; 0. Set up `detubifier-regexp-replacement-pairs'.
;; 1. Mark that text.
@@ -41,7 +39,8 @@
;;; Code:
(defcustom detubifier-regexp-replacement-pairs
- '(("youtube\\.com" . "invidious.jing.rocks")
+ '(("www\\.youtube\\.com" . "invidious.jing.rocks")
+ ("youtube\\.com" . "invidious.jing.rocks")
("youtu\\.be/" . "invidious.jing.rocks/watch?v=")
("twitter.com" . "nitter.poast.org"))
"List of pairs, each with a regexp and its replacement."