首页 > 如果github下的项目和username.github.io下的子目录重名会有什么结果?

如果github下的项目和username.github.io下的子目录重名会有什么结果?

username.github.io 个人主页(有子目录test)

同时为一个test项目建立了项目主页

两者都指向了:username.github.io/test


有打这么多字的时间,自己都试出结果了


参见官网的说明。

If the custom domain in your CNAME file is already used by another
GitHub Pages site, you will receive a page build warning. A custom
domain in a CNAME file can only be used once. Here are some examples
of when you'll receive a page build warning for a duplicate custom
domain:

If you have an an apex domain such as example.com in your CNAME file,
this means that either example.com or its www subdomain
(www.example.com) has been used in a CNAME file in another repository
and is being used by the corresponding GitHub Pages site.

Likewise, if you have a www subdomain such as www.example.com in your
CNAME file, this means that either www.example.com or its apex domain
(example.com) has been used in a CNAME file in another repository and
is being used by the corresponding GitHub Pages site.

就是说,只有第一个项目是有效的。

【热门文章】
【热门文章】