【问题标题】:Using emacs org-mode, how to publish the unchanged files in a project?使用emacs org-mode,如何在项目中发布未更改的文件?
【发布时间】:2014-01-21 12:54:38
【问题描述】:

我正在运行 Emacs 24.3 和 org-mode 8.25f。当我使用 M-x org-publish 命令时,org-mode 只会将新的 .org 文件转换为 .html 并跳过自上次发布操作以来未修改的所有其他文件。

但是,通常我会在发布设置和 CSS 代码中进行一些更改。我希望它们对所有文件生效,而不仅仅是最近修改的文件。

那么,我可以告诉 org-mode 不要跳过这些未更改的文件吗?

【问题讨论】:

    标签: emacs publish org-mode


    【解决方案1】:

    这应该可行:

    M-: (org-publish "project name" t)
    

    这运行org-publishFORCE 设置为t。来自文档:

    When optional argument FORCE is non-nil, force publishing all
    files in PROJECT.  With a non-nil optional argument ASYNC,
    publishing will be done asynchronously, in another process.
    

    作为you discovered yourself,一个prefix argument will also force Org to publish all files

    C-u M-x org-publish
    

    【讨论】:

    • 如何将此功能添加到配置文件中?
    • “将此功能添加到配置文件”是什么意思?您想在运行org-publish 时将其设为默认值吗?
    • 是的,我只是制作自己的函数,但也许它可以更简单。
    • 这可能是最好的。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-01-23
    • 2015-10-05
    • 2011-08-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多