6

tasks/org-agenda-files变量中有一个目录。当我通过命令( )将文件添加到org-agenda-files变量时,目录路径将替换为当前位于该目录中的文件的路径。这很糟糕,因为当我稍后添加一些文件时,它们不会对我的议程做出贡献。C-c [org-agenda-file-to-fronttasks/

有什么方法可以避免这种情况,还是我坚持手动添加文件和目录org-agenda-files

这个问题在组织模式中得到承认 - 用纯文本组织你的生活!

Emacs 版本:24.0.50.1 组织模式版本:7.8.09

4

1 回答 1

1

You could define a command that just adds a file to org-agenda-files without calling org-agenda-files-to-front, and then rebing that to C-c [. For example:

(defun my-org-agenda-file-to-front ()
  (interactive)
  (setq org-agenda-files (append org-agenda-files (list (buffer-file-name (current-buffer))))))

(define-key org-mode-map (kbd "C-c [") `my-org-agenda-file-to-front)
于 2014-05-05T23:54:18.997 回答