summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClément Lassieur <clement.lassieur@parrot.com>2019-04-30 18:28:21 +0200
committerClément Lassieur <clement.lassieur@parrot.com>2019-04-30 18:28:21 +0200
commit865b9fb6eb20d01d7c476614bbc6aff41a04025d (patch)
treeb817a78ff4ffa0299f18eb47e958e29cf1a4c614
parentad881d5dbd1744d67a816c5be71eabc90b96495d (diff)
downloademacs-865b9fb6eb20d01d7c476614bbc6aff41a04025d.tar.gz
dired: fix bug in my-dired-open-file
-rw-r--r--stow/home/.emacs.d/conf/my-dired.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/stow/home/.emacs.d/conf/my-dired.el b/stow/home/.emacs.d/conf/my-dired.el
index 25226ad..8d7c6c9 100644
--- a/stow/home/.emacs.d/conf/my-dired.el
+++ b/stow/home/.emacs.d/conf/my-dired.el
@@ -21,9 +21,9 @@
(defun my-dired-open-file ()
"In dired, open the file named on this line."
(interactive)
- (let* ((tramp-file (dired-get-filename nil t))
- (file (file-remote-p (file-truename tramp-file) 'localname)))
- (call-process "xdg-open" nil 0 nil file)))
+ (let* ((file (file-truename (dired-get-filename nil t)))
+ (remote-file (file-remote-p file 'localname)))
+ (call-process "xdg-open" nil 0 nil (or remote-file file))))
;;;###autoload
(defun my-dired-maybe-hide-dotfiles (&optional _ignore-auto _noconfirm