使用master分支创建github page请求不到css文件夹下的资源

今天尝试使用hexo 和github搭建自己的博客但是css文件夹下的资源请求不到。不知道原因。
网页地址
代码地址

错误信息
错误信息

请大家帮忙解决,已经尝试一天了也不行

阅读 6.8k
2 个回答

帐号下创建了css仓库造成的

Hi there,

You currently have a repository xiyuanyuan/css, which is conflicting with the css folder in your repo xiyuanyuan/xiyuanyuan.github.io.

Both of these would be displayed at xiyuanyuan.github.io/css. When this happens, the repo trumps the folder.

You'll need to either rename the folder or rename the repository.

Best,
Shawna

首先,木有看到你github下的这个repo有gh-pages的分支啊。。。so,你哪儿来的github.io可以访问呢。

其次,就算你有个gh-pages分支,generate了page,你的路径里还少了一段,项目名(xiyuanyuan.github.io)的上下文啊

https://xiyuanyuan.github.io/...

格式为:"https://+username+.github.io/+repo_name+/+static_source_path"

btw,你还可以通过
https://raw.githubusercontent...

格式为:"https://raw.githubusercontent.com/+username+/+repo_name+/+branch+/static_srouce_path"

来访问你repo的静态资源哟

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进