summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorKyle Meyer <kyle@kyleam.com>2014-04-25 21:16:38 -0400
committerKyle Meyer <kyle@kyleam.com>2014-04-25 21:16:38 -0400
commit4693eaac7178389cfe303f8669c91a1f1b5066e0 (patch)
tree1776e234b84d3fa1bc55aff5eb877cce58e2552d /lisp
parent6f491087feedfe0d711fd4c5cec52592ac082296 (diff)
downloademacs.d-4693eaac7178389cfe303f8669c91a1f1b5066e0.tar.gz
Make org-open-file available in dired
Diffstat (limited to 'lisp')
-rw-r--r--lisp/init-dired.el8
1 files changed, 8 insertions, 0 deletions
diff --git a/lisp/init-dired.el b/lisp/init-dired.el
index ac4c279..597df4c 100644
--- a/lisp/init-dired.el
+++ b/lisp/init-dired.el
@@ -48,4 +48,12 @@
(define-key ctl-x-4-map "D" 'km/dired-switch-to-buffer-other-window)
(global-set-key (kbd "C-x D") 'km/dired-switch-to-buffer)
+(defun km/org-open-dired-file ()
+ (interactive)
+ (org-open-file (dired-get-filename)))
+
+(eval-after-load 'org
+ ;; This overrides `dired-find-file', which is also bound to "f".
+ '(define-key dired-mode-map "e" 'km/org-open-dired-file))
+
(provide 'init-dired)