gpt4 book ai didi

markdown - Pandoc Markdown 到纯文本格式

转载 作者:行者123 更新时间:2023-12-02 08:23:57 24 4
gpt4 key购买 nike

我的机器上最新安装的 Pandoc(pandoc 1.13.2.1)版本似乎有问题。使用之前安装的版本,从 Markdown 到纯文本的转换会生成 'Setext-style headers---'=' for H1 and '-' for H2---在纯文本输出中。此外,我还注意到两个不确定的问题:

  • Pandoc 现在会自动为标题生成大写字母
  • Pandoc 现在在 title 之前添加了两个新行 (\n)

  • 在过去的几分钟里,我一直在玩不同的 pandoc 选项,但运气不佳。

    我如何转换 图#1 图#3

    环境
    pandoc (pandoc 1.13.2.1)
    库本图 15.10

    插图 #1:输入 Markdown 文件
    # Title

    ## Section
    * This is the section.

    ### Subsection
    * This happens to be the subsection

    插图#2:运行后输出纯文本 pandoc -f markdown -t plain pandoc_markdown_issue.md
    TITLE


    Section

    - This is the section.

    Subsection

    - This happens to be the subsection

    插图 #3:所需的输出
    Title
    =====

    Section
    -------
    - This is the section.

    Subsection
    ----------
    - This happens to be the subsection

    最佳答案

    纯文本编写器已更改为使用古腾堡计划纯文本书籍的通用格式。当然,没有选择会让所有人满意。对于您提供的示例,使用 Markdown writer 效果会很好。

    关于markdown - Pandoc Markdown 到纯文本格式,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34132549/

    24 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com