wangchucheng / hugo-eureka

Eureka is a feature-rich and highly customizable Hugo theme.
https://www.wangchucheng.com/en/docs/hugo-eureka/
Apache License 2.0
920 stars 192 forks source link

Error: module "wangchucheng.com/hugo-eureka" not found #206

Closed Fatalerr closed 2 years ago

Fatalerr commented 2 years ago

Describe the bug

按文档安装好eureka 0.9.3版本后,运行hugo serve 失败,提示以下信息:

Error: module "wangchucheng.com/hugo-eureka" not found; either add it as a Hugo Module or store it in "c:\\playground\\hugodemo\\themes".: module does not exist

To Reproduce

Does this issue reproduce with the latest release? YES

Steps to reproduce the behavior:

  1. 按文档新建一个site

    hugo new site <hugodemo> 
  2. 按照hugo-eureka的文档以submodule的形式添加hugo-euraka

  git submodule add https://github.com/wangchucheng/hugo-eureka.git themes/eureka   
  1. 按照hugo-eureka的文档将theme/eureka/exampleSite下的config和contents文件拷贝到hugodemo的根目录下
  2. 在项目的根目录下运行hugo serve, 即出现以上错误。

Environment

Additional context

Uncomment when not installing with Hugo Modules

theme: eureka

Comment when not installing with Hugo Modules

theme: wangchucheng.com/hugo-eureka

If you cannot access the Github mirror, you can also use the Gitee mirror: gitee.com/wangchucheng/hugo-eureka

paginate: 3 copyright: > © 2021 WANG Chucheng and <a href="https://www.ruiqima.com/">MA Ruiqi enableEmoji: true enableGitInfo: false summaryLength: 75

defaultContentLanguage: en hasCJKLanguage: false # Set true for Chinese/Japanese/Korean. defaultContentLanguageInSubdir: false

Uncomment for google analytics

googleAnalytics: UA-123-45

markup:

Do not modify markup.highlight

highlight: codeFences: false noClasses: false tableOfContents: startLevel: 2 endLevel: 6 ordered: false goldmark: renderer: unsafe: true

taxonomies: category: categories tag: tags series: series author: authors

build: useResourceCacheWhen: always

wangchucheng commented 2 years ago

如果使用git submodule安装,需按config文件注释中说明的,将theme改为eureka而非默认值。祝好!

Fatalerr commented 2 years ago

謝謝提醒!我才看清楚是注释里说的是hugo module而不是Git submoudle。 我将theme改为eureka后,还是出错:

Error: module "wangchucheng.com/hugo-marble/utils" not found; either add it as a Hugo Module or store it in "c:\\playground\\hugodemo\\themes".: module does not exist
wangchucheng commented 2 years ago

謝謝提醒!我才看清楚是注释里说的是hugo module而不是Git submoudle。 我将theme改为eureka后,还是出错:


Error: module "wangchucheng.com/hugo-marble/utils" not found; either add it as a Hugo Module or store it in "c:\\playground\\hugodemo\\themes".: module does not exist

请按照文档说明使用稳定版本而非main分支的最新commit。

Fatalerr commented 2 years ago

按照文档说明checkout了v0.9.3版,module "wangchucheng.com/hugo-marble/utils" not found 错误消失,但又出现以下错误:

 hugo serve                                                                                                                                                   
Start building sites … 
hugo v0.101.0-466fa43c16709b4483689930a4f9ac8add5c9f66+extended windows/amd64 BuildDate=2022-06-16T07:09:16Z VendorInfo=gohugoio
WARN 2022/07/10 16:51:32 Param 'hero' in params.toml is deprecated and will be removed in Eureka v1.0.0. See https://www.wangchucheng.com/en/docs/hugo-eureka/h
omepage-configuration/
Error: Error building site: POSTCSS: failed to transform "css/eureka.css" (text/css): resource "css/css/eureka.css_59122205213644db2a335025f85b41bf" not found 
in file cache
Built in 255 ms
Fatalerr commented 2 years ago

另外说明一下,我在原有的site的下面就会出错,但重新建一个新的site就没这个问题。