Skip to content
项目

jobindjohn/obsidian-publish-mkdocs

在 GitHub 查看

关于

使用 MkDocs 将 Obsidian/Foam 笔记发布到 GitHub Pages 的模板

效率与自动化

这些数字如何统计

实测星标增长

24小时
0
7天
+2
15天
+3
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

Publish your Obsidian Notes

MkDocs template Built with Material for MkDocs

Would you like to take some of your notes in Obsidian and make it public?

This template gives you an easy (and automated) way to publish your Obsidian notes (or blog!) on your Github pages.

With this template, you get these out-of-the-box:

  • an awesome website based on Material theme, complete with a search bar (Checkout this template repo published here)
  • get the Obsidian/Roam style [[wikilinks]] from your vault in your published notes
  • Toggle between light and dark mode
  • Blog folder

Quick start

  1. Create a new github repository using this template. Click the green button at the top or use this link.

  1. Give a name to your repository. By default your notes will be published at <https://username.github.io/repo-name/>
    • Copy only the main branch while creating the repo from the template
  2. Clone the repository you generated into your Obsidian folder/vault.
  3. Move your notes that you would like to make public to the repo-name/docs folder.
    • Easiest way to do this would be using drag and drop within Obsidian
  4. Commit and push the changes. Github actions will take care of the rest, publishing your notes using MkDocs, with the Material theme.
  5. Go to Settings > Pages and select the select the Source as your gh-pages branch.

Not working for you? Open an issue and let me know what went wrong.

Configuring your website

How do I arrange notes as sections and pages?

By default, the sections and pages will follow the folder structure within /docs. The folders and sub-folders will show up as sections. Try not to have white spaces in your folder and file names, as these will be converted to HTML links. The webpage heading will be the same as the first-level heading in the markdown note.

  • If you would like to arrange the pages manually, then use the nav option in the mkdocs.yml configuration file at the root of this repo to set custom page navigation.
    • For example, see the setup for the Blue Book at github. Managing each page using nav can become cumbersome as the number of notes increase though!
  • The Materials theme provides multiple options to arrange sections, use navigation tabs, and many other helpful navigation setups

Alternatives

Other interesting projects

探索相关项目

加载中…