-
Notifications
You must be signed in to change notification settings - Fork 152
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
Your theme's demo is not working on the Hugo Themes website #148
Comments
@onedrawingperday thank you very much for the hint! I will update and commit the |
I've just wanted to fix this issue and followed the Readme, but no The styles get generated as follows: {{ $variables := resources.Get "sass/_variables.scss" }}
{{ $theme := resources.Get "sass/theme.scss" }}
{{ $combined := slice $variables $theme | resources.Concat "sass/combined.scss" | resources.ExecuteAsTemplate "sass/combined.scss" . }}
{{ $style := $combined | toCSS | minify | fingerprint }}
<link rel="stylesheet" href="{{ $style.RelPermalink }}"> and scripts: {{ $js := resources.Get "js/externalDependencies.js" }}
{{ $secureJS := $js | resources.Fingerprint "md5" }}
<script type="text/javascript" src="{{ $secureJS.Permalink }}" integrity="{{ $secureJS.Data.Integrity }}"></script>
{{ $jsTemplate := resources.Get "js/theme.js" }}
{{ $secureJS := $jsTemplate | resources.ExecuteAsTemplate "js/theme.js" . | fingerprint "md5" }}
<script type="text/javascript" src="{{ $secureJS.Permalink }}" integrity="{{ $secureJS.Data.Integrity }}"></script> So I'm using the However a Will it work to copy and commit this folder? If so, maybe we should update the README of hugo themes, otherwise I would kindly ask for your help ;) |
@Lednerb You need to use
You need to execute Once you do this let me know so that I can test your theme with the Build Script. Thanks. |
Please have a look at 8770b9b. I've updated to |
8770b9b looks fine. Regarding the
P.S. Whenever you update your theme's SCSS you will need to generate your theme's resources and then commit them again. |
Hi again and thank you for the instructions! I've followed them and again there is a
Thanks for the hint, I will write a deploy script when the I'm using the latest hugo extended version: |
Hi @Lednerb and thanks for your response. I am not using Hugo Extended myself since I do not rely on SCSS. Can you please tell me if the a resources folder If the folder contains the generated resources, then please commit the entire folder under the root of your theme's repository, so that I can test the theme demo with the Build Script. Also note that just a few hours ago the README of the Hugo Themes repository was updated. Apparently the use of Sorry about that, but we were not aware of the impact this bug report had on Theme Demos of the Hugo Website until yesterday. |
Hi again @onedrawingperday I've updated the repo and committed the Please let me know if it will work with this changes. |
@Lednerb Now your basic CSS is getting served when I test your theme's demo. However the icon fonts are missing because you have hard-coded the Example Site's To fix this issue under
The way you have hard-coded the URLs makes them point to Please do the above change, re-generate your theme's resources and let me know so that i can test further. P.S. I am tagging @digitalcraftsman because I think that he needs to know about the issue with the hard-coded icon fonts URLs. |
Eh. I see that you pushed a new commit as I was updating the code snippet. Bear with me just a minute. I'll test your commit right now and let you know. This the first time I encounter this issue so I don't have a ready-made fix. I need to test first. |
thanks for the critical hint here. I've forgotten this part. New version pushed. Thank you very much for your help, time and engagement not only on this theme but also here gohugoio/hugoThemes#430 (comment) and in general with the Hugo Theme department! 👍 🎉 Great work! |
@onedrawingperday done. |
I had to install Hugo Extended to troubleshoot this issue. Please delete the entire existing Let me know once you do this so that I can test with the contents of your repository. |
Hello again @Lednerb Any updates on this? You only need to regenerate your theme's resources as you did before and commit them again in your repo so that the icon fonts in your theme's demo load properly on the Hugo website. Can you please look into it? Thanks. |
sorry for the delay. I've uploaded it again in f72e2b3 Please check. If there's still an issue and you have the solution for this... I'm open for PRs ;) Thank you for pinging here again. |
@onedrawingperday thanks for the PR, it's merged. |
Hello @Lednerb
I see that since commit 79846b1 your theme is using Hugo Pipes.
However you have not committed the generated resources of your theme and as a result your theme's demo fails to generate on the Hugo website.
To fix this issue please have a look at the updated README of Hugo Themes: https://github.com/gohugoio/hugoThemes#resources You need to commit the
/resources/
directory and its contents in your theme's repository.If you have any questions do not hesitate to ask me or @digitalcraftsman
The text was updated successfully, but these errors were encountered: