From 8aeb088deb019be7791c984ff812a053641ff4a2 Mon Sep 17 00:00:00 2001 From: mms Date: Thu, 29 Feb 2024 23:50:42 +0100 Subject: feat: links --- mms-misc.org | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'mms-misc.org') diff --git a/mms-misc.org b/mms-misc.org index 2ec07d1..1b7b7f2 100644 --- a/mms-misc.org +++ b/mms-misc.org @@ -127,15 +127,19 @@ First, let's be able to run Youtube inside emacs Then, let's create linkhandler to pass the link to the correct handler. #+begin_src emacs-lisp - (defun mms-open-link-under-point () - (interactive) - (setq url (thing-at-point 'url)) - (cond - ((string-match "youtube.com" url) (yeetube-search url)) - (t (eww url))) - ) + (defun mms-open-link-under-point () + (interactive) + (let ((url (thing-at-point 'url)))) + (cond + ((string-match "youtube.com" url) (yeetube-search url)) + (t (eww url))) + ) #+end_src +#+RESULTS: +: mms-open-link-under-point + + And I want to have as =leader - enter - enter= #+begin_src emacs-lisp -- cgit v1.2.3