Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: module "github.com/FortAwesome/Font-Awesome" not found; #836

Closed
strattonbrazil opened this issue Jan 15, 2022 · 7 comments

Comments

@strattonbrazil
Copy link

I'm very new to hugo. I'm running hugo 0.92.0 and installed docsy as a submodule in the themes directory. When running most hugo commands I get an error about Font-Awesome that seems to prevent any progress. It looks like a missing dependency, but I don't see any additional requirements called out in the docs.

$ hugo server
Error: module "github.com/FortAwesome/Font-Awesome" not found; either add it as a Hugo Module or store it in "/home/user/Public/test/themes".: module does not exist
@deining
Copy link
Collaborator

deining commented Jan 17, 2022

Most likely this is due to errors introduced in #801. I just submitted a PR that addresses these errors.

Meanwhile you can work around this. Inside your config.toml, identify the following line:

theme = ["docsy"]

Remove this line and replace it with the settings given in the code box below:

[module]
replacements = "github.com/FortAwesome/Font-Awesome -> ., github.com/twbs/bootstrap -> ."
[[module.imports]]
path = "docsy"

Does this solve your issue?

@strattonbrazil
Copy link
Author

strattonbrazil commented Jan 17, 2022 via email

@iamsalmakolkari
Copy link

Most likely this is due to errors introduced in #801. I just submitted a PR that addresses these errors.

Meanwhile you can work around this. Inside your config.toml, identify the following line:

theme = ["docsy"]

Remove this line and replace it with the settings given in the code box below:

[module]
replacements = "github.com/FortAwesome/Font-Awesome -> ., github.com/twbs/bootstrap -> ."
[[module.imports]]
path = "docsy"

Does this solve your issue?

This resolved my issue. Thanks!!

@strattonbrazil
Copy link
Author

strattonbrazil commented Jan 17, 2022

That resolved it for me as well. Thanks!

You are welcome.

Is this placeholder code and eventually using the theme attribute will work

No, the theme attribute is outdated.

or is this the new format going forward?

Yes, that's the new format, it's essential when using hugo modules, so let's use it in all cases!

localrivet added a commit to k8scommerce/k8scommerce.github.io that referenced this issue Jan 18, 2022
@amirootyet
Copy link

I too had this error after updating Docsy submodule:

From https://github.com/google/docsy
   c9e8363..b6af369  master     -> origin/master
Submodule path 'themes/docsy': checked out 'b6af3699c65dd089f453700bee858c1de7d73dd7'

I tried to fix it using the advice by @strattonbrazil. However, I now have an issue where running the server now doesn't default to the /en (English) at the homepage. My documents are stored under content/en/ and the following setting in my config.toml used to ensure that it defaults to English:

contentDir = "content/en"
defaultContentLanguage = "en"
defaultContentLanguageInSubdir = false

Any solutions for this? I would like the localhost:1313 to treat the content/en/ as the contentDir.

@chalin
Copy link
Collaborator

chalin commented Mar 28, 2022

Can this issue be closed?

@amirootyet, I think that you're hitting the same problem I did. Can you try the solution documented here: https://discourse.gohugo.io/t/content-mount-problem-for-single-language-multilingual-site/37215/8?u=chalin, that is:

  • Delete the contentDir entry from your config
  • Add the following config:
    [[module.mounts]]
    source = "content/en"
    target = "content"

@chalin
Copy link
Collaborator

chalin commented Jun 10, 2023

Closing. Create a new issue if the problem persists.

@chalin chalin closed this as not planned Won't fix, can't repro, duplicate, stale Jun 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants