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

Support for hugo module #502

Closed
KarthikNayak opened this issue Jan 1, 2021 · 2 comments · Fixed by #534
Closed

Support for hugo module #502

KarthikNayak opened this issue Jan 1, 2021 · 2 comments · Fixed by #534

Comments

@KarthikNayak
Copy link

Hello,

I was recently to get this theme working with hugo module, but it doesn't seem to work.

❯ hugo new site karthik
...
❯ hugo mod init karthik
go: creating new go.mod: module karthik
❯ hugo mod get -u

hugo: downloading modules …
go: github.com/luizdepra/hugo-coder upgrade => v0.0.0-20201215193806-dbe21a7fdf0d
hugo: collected modules in 3793 ms
❯ hugo serve -D
Start building sites …
WARN 2021/01/01 15:17:28 found no layout file for "HTML" for kind "home": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2021/01/01 15:17:28 found no layout file for "HTML" for kind "taxonomy": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.
WARN 2021/01/01 15:17:28 found no layout file for "HTML" for kind "taxonomy": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.

                   | EN
-------------------+-----
  Pages            |  3
  Paginator pages  |  0
  Non-page files   |  0
  Static files     |  0
  Processed images |  0
  Aliases          |  0
  Sitemaps         |  1
  Cleaned          |  0

Built in 1 ms
Watching for changes in /Users/temporaryadmin/karthik/{archetypes,content,data,layouts,static}
Watching for config changes in /Users/temporaryadmin/karthik/config.toml, /Users/temporaryadmin/karthik/go.mod
Environment: "development"
Serving pages from memory
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
Web Server is available at //localhost:1313/ (bind address 127.0.0.1)
Press Ctrl+C to stop
WARN 2021/01/01 15:17:40 found no layout file for "HTML" for kind "home": You should create a template file which matches Hugo Layouts Lookup Rules for this combination.

Whereas my config is

[module]
  [[module.imports]]
    path = "github.com/luizdepra/hugo-coder"


theme = "hugo-coder"


baseURL = "http://example.org/"
languageCode = "en-us"
title = "My New Hugo Site"
@luizdepra
Copy link
Owner

Well, I never used Hugo Modules, so I need to test it first.
But, try to copy the config from exampleSite. I don't remember, but I think the theme will break if there are some configurations missing.

@KarthikNayak
Copy link
Author

@luizdepra Thanks for your reply. I actually did try it out with my blog. It still broke. I remember also trying with the example site.

freeformz added a commit to freeformz/hugo-coder that referenced this issue Mar 21, 2021
freeformz added a commit to freeformz/hugo-coder that referenced this issue Mar 21, 2021
luizdepra added a commit that referenced this issue Mar 25, 2021
* Add support for using as a Hugo module

Fixes #502

* Don't need/want the theme directory with modules

* Fix go.{mod,sum} files

* Set go version and hugo version everywhere

Co-authored-by: Luiz F. A. de Prá <[email protected]>
wlemuel pushed a commit to wlemuel/hugo-coder that referenced this issue Jun 22, 2021
* Add support for using as a Hugo module (luizdepra#534)

* Add support for using as a Hugo module

Fixes luizdepra#502

* Don't need/want the theme directory with modules

* Fix go.{mod,sum} files

* Set go version and hugo version everywhere

Co-authored-by: Luiz F. A. de Prá <[email protected]>

* Remove hugo mod from exampleSite and Netlify build

* Bump hugo version

* Move env vars inside netlify.toml

Co-authored-by: Edward Muller <[email protected]>
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

Successfully merging a pull request may close this issue.

2 participants