Skip to content

Cannot generate properly on GitHub Actions. 本地成功而在 GA 上 generate 不能得到正确的 public 目录。 #5512

Closed Answered by inaku-Gyan
inaku-Gyan asked this question in Question / Answer
Discussion options

You must be logged in to vote

解决了。。。

Cause:
因为安装主题时使用的 git clone,导致主题文件夹下有一个隐藏的 .git 目录。push 到 GitHub 中后,主题的那个文件夹就被 GitHub 判定为了一个 submodule,而 submodule 不能被直接打开,这导致 workflow 上的 Hexo 程序打不开主题文件夹,就 hexo g 不出东西。

Solution:
把主题文件夹下的 .git 删除,重新推送到 GH。

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by inaku-Gyan
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant