Emacs Org-mode - 导出到另一个目录? [英] Emacs Org-mode - Export to another directory?

查看:64
本文介绍了Emacs Org-mode - 导出到另一个目录?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道这有点小,但它一直困扰着我.我正在为一个项目使用 Org-mode,我倾向于经常导出为 PDF 或 HTML,这使我的目录中散落着 PDF、Tex 和 HTML 文件.有没有办法将 Org 模式导出到另一个位置,也许是一个名为 ./exports 的子目录?

I know this is kind of minor, but it's been bugging me. I'm using Org-mode for a project and I tend to export to either PDF or HTML rather frequently and it leaves my directory littered with PDF, Tex, and HTML files. Is there a way to have Org-mode export to another location, perhaps a subdirectory called ./exports?

推荐答案

除了按照@user1248256 的建议修改你的 org-publish-project-alist 变量来使用发布之外,你可以直接在您的文件中指定 org-export-publishing-directory 变量:

In addition to the use of publishing by modifying your org-publish-project-alist variable as @user1248256 suggested, you can directly specify the org-export-publishing-directory variable within your file:

#+bind: org-export-publishing-directory "./exports"

* This is a test headline
Some text here.  This should be exported to the "./exports" directory.

导出时,它将被放置在exports"目录中,但前提是该目录存在.如果它不存在,您将在控制台中收到一条错误消息.

Upon export it will be placed in the "exports" directory, but only if that directory exists. If it does not exist, you will get an error message in the console.

这篇关于Emacs Org-mode - 导出到另一个目录?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆