Skip to content

Instantly share code, notes, and snippets.

@TakesxiSximada
Created August 31, 2018 07:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TakesxiSximada/a0e65be31cecdaeac5ea602734283f85 to your computer and use it in GitHub Desktop.
Save TakesxiSximada/a0e65be31cecdaeac5ea602734283f85 to your computer and use it in GitHub Desktop.
複数のorg-modeのファイルをF11キーで切り替える
(use-package dash)
(setq our-org-files '("/path/to/your/org-file-01.org"
"/path/to/your/org-file-02.org"
"/path/to/your/org-file-03.org"
))
(defun our-org-next-file ()
(if (member (buffer-file-name) our-org-files)
(nth (% (+ (-elem-index (buffer-file-name) our-org-files) 1)
(length our-org-files)) our-org-files)
(car our-org-files)))
(defun our-toggle-open-org-file ()
(interactive)
(find-file (our-org-next-file)))
(bind-key "<f11>" 'our-toggle-open-org-file)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment