如题,我想要导出 markdown~/org-mode/markdown/
导出 html~/org-mode/html/


(defun org-md-export-to-markdown (&optional async subtreep visible-only)
  "Export current buffer to a Markdown file.
If narrowing is active in the current buffer, only export its
narrowed part.
If a region is active, export that region.
A non-nil optional argument ASYNC means the process should happen
asynchronously.  The resulting file should be accessible through
the `org-export-stack' interface.
When optional argument SUBTREEP is non-nil, export the sub-tree
at point, extracting information from the headline properties
When optional argument VISIBLE-ONLY is non-nil, don't export
contents of hidden elements.
Return output file's name."
  (let ((outfile (org-export-output-file-name ".md" subtreep)))
    (org-export-to-file 'md outfile async subtreep visible-only)))


一种方法是自己移过去,只是这样不灵活。org-export-to-file 返回是导出的文件名:

(defun [email protected] ()
   (format "mv -v %s %s"
           (shell-quote-argument (org-md-export-to-markdown))

也可以直接 advice org-md-export-to-markdown

Thank you,这个可以用