Skip to content

如何自定义首页的md文件路径 #159

Answered by sun0225SUN
LasyIsLazy asked this question in Q&A
Discussion options

You must be logged in to vote

其实我们可以换一种思路,"修改" GitHub 的 Readme.md 位置

https://docs.github.com/zh/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-readmes

如果将自述文件放在存储库隐藏的 .github 目录、根目录或 docs 目录中,GitHub 将识别自述文件并自动向存储库访问者显示。
如果存储库包含多个自述文件,则按以下顺序从各位置中选择显示的文件:.github 目录,然后是存储库的根目录,最后是 docs 目录。

根据优先级,把GitHub的Readme.md写在 .github 目录下就可以了,例如:https://github.com/sun0225SUN/hao-docs

Replies: 3 comments 3 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@LasyIsLazy
Comment options

@recoluan
Comment options

Comment options

You must be logged in to vote
1 reply
@LasyIsLazy
Comment options

Answer selected by recoluan
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants