From 05791ee8b63f37513fb1eaf1dcef77de5227994d Mon Sep 17 00:00:00 2001 From: bd Date: Sun, 27 Oct 2024 21:11:19 -0400 Subject: read desc: browsing+bookmarking interface, remove popper, no work... browsing+bookmarking interface, remove popper, no workspaces only tabs, custom password-store, exwm use window title, colonq selector, theme changes --- .config/emacs/modules/bd--files.el | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to '.config/emacs/modules/bd--files.el') diff --git a/.config/emacs/modules/bd--files.el b/.config/emacs/modules/bd--files.el index b8a5f4a..6ea121b 100644 --- a/.config/emacs/modules/bd--files.el +++ b/.config/emacs/modules/bd--files.el @@ -3,14 +3,15 @@ ;;; Code: +(require 'recentf) (defmacro bd/defun-find-file-wrapper (name types open-f) `(defun ,name (f &rest args) "Wrapper around F (find-file), passing ARGS." (if (string-match (regexp-opt ,types) (or (file-name-extension (car args)) "")) - (progn - (,(eval open-f) (car args)) - (recentf-add-file (car args)) - nil) + (progn + (,(eval open-f) (car args)) + (recentf-add-file (car args)) + nil) (apply f args)))) ;;;; dired @@ -39,8 +40,8 @@ (start-process (concat "zathura (" (file-name-base file) ")") nil "zathura" (expand-file-name file))) (bd/defun-find-file-wrapper bd/pdf-find-file-wrapper - '("epub" "pdf") - #'bd/zathura) + '("epub" "pdf") + #'bd/zathura) (advice-add 'find-file :around #'bd/pdf-find-file-wrapper) ;; video @@ -50,8 +51,8 @@ (bd/defun-find-file-wrapper bd/video-find-file-wrapper - '("mkv" "mov" "mp4" "webm" "m4v" "wav" "mp3" "opus" "ogv" "flac") - #'bd/mpv) + '("mkv" "mov" "mp4" "webm" "m4v" "wav" "mp3" "opus" "ogv" "flac") + #'bd/mpv) (advice-add 'find-file :around 'bd/video-find-file-wrapper) ;; image @@ -59,8 +60,8 @@ "Open FILE with nsxiv" (start-process (concat "nsxiv (" (file-name-base file) ")") nil "nsxiv" (expand-file-name file))) (bd/defun-find-file-wrapper bd/image-find-file-wrapper - '("jpg" "jpeg" "png" "webp" "bmp" "ico" "gif" "JPG" "PNG") - #'bd/nsxiv) + '("jpg" "jpeg" "png" "webp" "bmp" "ico" "gif" "JPG" "PNG") + #'bd/nsxiv) (advice-add 'find-file :around 'bd/image-find-file-wrapper) -- cgit v1.2.3