summary refs log tree commit diff
diff options
context:
space:
mode:
authornoa2025-02-16 22:08:05 +0800
committernoa2025-02-16 22:08:05 +0800
commit42c531e6c74d9e91dbddd120a5ebe359f195599c (patch)
tree8fd005f9ce31a5307a2ca992ee0347e3843bb014
parentb55cdf03385246782920b36c31b9e5b7b5a2dcf3 (diff)
Add alternative browse-url function to email pages to myself
-rw-r--r--emacs/init.el5
1 files changed, 5 insertions, 0 deletions
diff --git a/emacs/init.el b/emacs/init.el
index 6f1f41f..2cb8681 100644
--- a/emacs/init.el
+++ b/emacs/init.el
@@ -974,6 +974,11 @@ With prefix argument TIME, also add the current time."
            (common-lisp-hyperspec-root "file:///usr/share/doc/hyperspec/"))
   :mode ((rx (or ".lisp" ".cl") eos) . common-lisp-mode))
 
+;; Write url to text file
+(defvar noa/record-url-file "~/Documents/Library/urls")
+(defun noa/record-url (url &rest args)
+  "An alternative browser function that appends the url to a file.  We do not pay attention to any arguments."
+  (write-region (concat url "\n") nil noa/record-url-file 'append))
 
 (defvar note/directory "~/Documents/Notes"
   "The directory in which notes are stored.")