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

Code breaks build #17

Open
ytrepidorosonomous opened this issue Dec 2, 2023 · 6 comments
Open

Code breaks build #17

ytrepidorosonomous opened this issue Dec 2, 2023 · 6 comments

Comments

@ytrepidorosonomous
Copy link

https://github.com/chollinger93/ink-free/blob/master/layouts/index.html#L32
That line breaks the build if wpm is not configured. You need to wrap it with with or if unless that is the intended behaviour.

@LaytonLee
Copy link

LaytonLee commented Mar 18, 2024

The wpm and maxTags parameters must be set in hugo.toml; otherwise, a build problem will occur. Additionally, I think it's better to set default values for them. Could you fix this issue, or would you mind if I pull a request to fix it? @chollinger93

@chollinger93
Copy link
Owner

I'd happily accept a PR @LaytonLee !

@LaytonLee
Copy link

I'd happily accept a PR @LaytonLee !

Thanks, I think there maybe 3 different ways to fix it:

  1. use with to set certain values for wpm and maxTags in layouts/index.html
  2. set the default values in data/default.toml and refer the value in layouts/index.html by using .Site.data.default.wpm and .Site.data.default.maxTags
  3. update README.md and tell users wpm and maxTags are required parameters

Personally, I prefer the last 2 solutions. I think it would be better if the theme could set and use a default configuration file, but it's not available currently: gohugoio/hugo#1344.

Which approach do you think is preferable? Alternatively, do you think there is a better solution?

@EndreEndi
Copy link

EndreEndi commented Sep 12, 2024

Hello, so i tried using fink-free, i'm absolutely new to hugo and don't know any programming, so i need help with this please.

When i run "hugo server -b http://10.10.1.45/blog -D --bind=0.0.0.0"

I get this
Error: add site dependencies: load resources: loading templates: "/home/eendi/blog/themes/ink-free/layouts/_default/terms.html:29:1": parse failed: template: _default/terms.html:29: unclosed action

I didn't make another issue because i figured this issue might be related?

@chollinger93
Copy link
Owner

Hello, so i tried using fink-free, i'm absolutely new to hugo and don't know any programming, so i need help with this please.

When i run "hugo server -b http://10.10.1.45/blog -D --bind=0.0.0.0"

I get this Error: add site dependencies: load resources: loading templates: "/home/eendi/blog/themes/ink-free/layouts/_default/terms.html:29:1": parse failed: template: _default/terms.html:29: unclosed action

I didn't make another issue because i figured this issue might be related?

Can you please make sure you're using the latest version of the theme, share the version of hugo you're using, and your config.toml file?

You can also try the following:

cd themes/ink-free/exampleSite
hugo serve  --themesDir ../..

The error in this issue only occurs when your config.toml isn't configured correctly.

@EndreEndi
Copy link

EndreEndi commented Sep 13, 2024

Hi, i've migrated to grav, someone told me that .md are limited and i found the workflow of doing a post being kind of a hassle, i have a homelab and i wanted to make a blog with what i do experiments and such.

I had the latest one that is avalable on "apt install hugo" and the latest update of ink-free because i git cloned it yesterday.

A friend of mine fixed it for me in the end but i moved to something else because of the workflow.
As for the config.toml, is the one for your blog (i tried to copy it, move the posts elsewhere not public in order to have templates because i don't know markdown, and post myself, because i liked the simplicity of the blog, in the config i just changed the domain name.

ANd btw, not sure if you know, on the blog repo, the deploy thing in the README.md dosen't work, the action is not found.

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

4 participants