diff --git a/custom/elon.el b/custom/elon.el new file mode 100644 index 0000000..c92f3bc --- /dev/null +++ b/custom/elon.el @@ -0,0 +1,23 @@ +;; does the job for now – could be improved! + +(defun elon () + (interactive) + (goto-char (point-min)) + (while (re-search-forward " twitter" nil t) + (setq position (random 7)) + (if (eq position 0) + (replace-match " xtwittexr") + (if (eq position 1) + (replace-match " txwitter") + (if (eq position 2) + (replace-match " twxitter") + (if (eq position 3) + (replace-match " twixtter") + (if (eq position 4) + (replace-match " twitxter") + (if (eq position 5) + (replace-match " twittxer") + (if (eq position 6) + (replace-match " twittexr") + (if (eq position 7) + (replace-match " twxitterx"))))))))))) diff --git a/custom/toot-mockup.el b/custom/toot-mockup.el new file mode 100644 index 0000000..8effb73 --- /dev/null +++ b/custom/toot-mockup.el @@ -0,0 +1,28 @@ +;; light mode only – not yet sure how to do dark mode in the most sensible way + +(defun addtoot () + (interactive) + (setq dispname (read-string "Display name: ")) + (setq avatar (read-string "Avatar URL (with https://): ")) + (setq fediname (read-string "Username: ")) + (setq instanceurl (read-string "Instance URL (without https://): ")) + (setq profileurl (read-string "Profile URL (with https://): ")) + (setq toottext (read-string "Text (HTML): ")) + (setq csstext (replace-regexp-in-string "\n") + (if repost + (insert (concat "
" reposter " shared a status by " fediname "
\n"))) + (insert (concat "
\n \n \n \n
\n " dispname "\n
@" fediname "@" instanceurl "
\n
\n
\n
\n

" csstext "

\n
\n " theday " " themonth ", " theyear "\n \n"))) + +(defun tootbuild () + (interactive) + (insert "
\n") + (addtoot) + (insert "
"))