Add key binding to visit init file and index.org

Inspired by http://emacsredux.com/blog/2013/05/18/instant-access-to-init-dot-el/
This commit is contained in:
2016-11-15 00:47:14 +01:00
parent e0e2fd262e
commit ef42a03d3a
2 changed files with 14 additions and 1 deletions

View File

@@ -11,3 +11,14 @@ buffer is not visiting a file, prompt for a file name."
(if buffer-file-name
(find-alternate-file tramp-path)
(find-file tramp-path))))
(defun gpolonkai/visit-init-file ()
"Open the init file."
(interactive)
(find-file-other-window user-init-file))
(defun gpolonkai/visit-org-index ()
"Visit the root of Org-mode notes."
(interactive)
(find-file-other-window (concat (file-name-as-directory org-directory)
"index.org")))