Skip to main content

此版本的 GitHub Enterprise 已停止服务 2022-06-03. 即使针对重大安全问题,也不会发布补丁。 要获得更好的性能、改进的安全性和新功能,请升级到 GitHub Enterprise 的最新版本。 如需升级方面的帮助,请联系 GitHub Enterprise 支持

Setting a Markdown processor for your GitHub Pages site using Jekyll

You can choose a Markdown processor to determine how Markdown is rendered on your GitHub Pages site.

GitHub Pages 适用于具有 GitHub Free 和组织的 GitHub Free 的公共仓库,以及具有 GitHub Pro、GitHub Team、GitHub Enterprise Cloud 和 GitHub Enterprise Server 的公共和私有仓库。

People with write permissions for a repository can set the Markdown processor for a GitHub Pages site.

GitHub Pages supports two Markdown processors: kramdown and GitHub's own Markdown processor, which is used to render GitHub Flavored Markdown (GFM) throughout GitHub Enterprise Server. For more information, see "About writing and formatting on GitHub."

You can use GitHub Flavored Markdown with either processor, but only our GFM processor will always match the results you see on GitHub Enterprise Server.

  1. 在 GitHub Enterprise Server 上,导航到站点的仓库。

  2. In your repository, browse to the _config.yml file.

  3. 在文件视图的右上角,单击 打开文件编辑器。 编辑文件按钮

  4. Find the line that starts with markdown: and change the value to kramdown or GFM. Markdown setting in config.yml

  5. 在页面底部,输入一条简短、有意义的提交消息,描述您对文件所作的更改。 您可以在提交消息中将提交归于多个作者。 更多信息请参阅“创建有多个合作作者的提交”。 有关更改的提交消息

  6. 在提交消息字段下面,确定是要将提交添� 到当前分支还是新分支。 如果当前分支是默认分支,则应选择为提交创建新分支,然后创建拉取请求。 更多信息请参阅“创建新的拉取请求”。 提交分支选项

  7. 单击 Propose new file(提议新文件)提议新文件按钮

Further reading