tomanistor / osprey

Simple, clean, and fast one-page Hugo portfolio theme accompanied by a blog
https://tomanistor.com
Apache License 2.0
184 stars 87 forks source link

Template fails a wercker based Hugo build #6

Closed RichardSage closed 7 years ago

RichardSage commented 7 years ago

i've been trying to use osprey as the theme for a hugo site hosted on github pages, using wercker to automatically build the site based on a push. The following is a list of errors that cause the wercker hugo build to fail ERROR: 2017/07/04 template: theme/_default/list.html:6: function "humanize" not defined ERROR: 2017/07/04 template: theme/_default/single.html:8: function "default" not defined ERROR: 2017/07/04 template: theme/partials/about.html:3: function "readDir" not defined ERROR: 2017/07/04 template: theme/partials/blog.html:12: function "default" not defined ERROR: 2017/07/04 Error while rendering section : html/template: "theme/_default/list.html" is an incomplete template

tomanistor commented 7 years ago

Hey @RichardSage, what versions of Hugo and GoLang are you using?

RichardSage commented 7 years ago

Hi Toma,

Hugo version is 0.14. The Werker package doesn't specify the version of GoLang

On Tue, 4 Jul 2017 at 22:12 Toma Nistor notifications@github.com wrote:

Hey @RichardSage https://github.com/richardsage, what versions of Hugo and GoLang are you using?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tomanistor/osprey/issues/6#issuecomment-312955487, or mute the thread https://github.com/notifications/unsubscribe-auth/AJzeAdYec8uLASoltNQD2dkWAvY5d3Pkks5sKqqggaJpZM4ONq3b .

tomanistor commented 7 years ago

You'll need the latest version of Hugo because 0.14 doesn't use those functions. This theme in particular works best with the current version of Hugo: 0.24.1.

https://github.com/gohugoio/hugo/releases

RichardSage commented 7 years ago

Thanks Toma, I'll look at changing it.

As an aside I noticed during building my site that I had to put assets (e.g images) into the images folder within the theme folder for them to display, not within the image folder within the main part of my project. I'm assuming in probably doing something stupid, is there a config setting that I might need to change?

Thanks in advance

On Wed, 5 Jul 2017 at 19:37 Toma Nistor notifications@github.com wrote:

You'll need the latest version of Hugo because 0.14 doesn't use those functions. This theme in particular works best with the current version of Hugo: 0.24.1.

https://github.com/gohugoio/hugo/releases

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tomanistor/osprey/issues/6#issuecomment-313189733, or mute the thread https://github.com/notifications/unsubscribe-auth/AJzeARCwB6N2YAJCtc5NeVZuFv9I0TRuks5sK9gDgaJpZM4ONq3b .

tomanistor commented 7 years ago

What is your static folder structure? The path to an image in the theme is /images/example-image.jpg.

In the config.toml file, for example, you can use your own logo by changing

logoBig = "/images/osprey-logo.png"

to your own image path.

RichardSage commented 7 years ago

Hello Toma,

I've re-installed the theme, but i'm still having issues with images in my /images/ folder not displaying (they do if i put them in the /images folder within the theme folder).

I've attached 3 screenshots of the 404, one of the example galleries where the image is not displaying, and the folder structure.

I'd really appreciate it if you could point me in the right direction as to how to resolve this as i'd relly like to use your theme for my site.

Thanks in advance

Richard

On Thu, 6 Jul 2017 at 02:07 Toma Nistor notifications@github.com wrote:

What is your static folder structure? The path to an image in the theme is /images/example-image.jpg.

In the config.toml file, for example, you can use your own logo by changing

logoBig = "/images/osprey-logo.png"

to your own image path.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tomanistor/osprey/issues/6#issuecomment-313267490, or mute the thread https://github.com/notifications/unsubscribe-auth/AJzeAcK2gR9RCUCCfuPzCMS9HP7TftU5ks5sLDM7gaJpZM4ONq3b .

RichardSage commented 7 years ago

Hello Toma,

I think i've resolved the issue, i created an images folder in the static folder in the root of my site (so root/static/images) and put my image in there and they are now displaying.

On Mon, 10 Jul 2017 at 13:22 Richard Sage sagey79@gmail.com wrote:

Hello Toma,

I've re-installed the theme, but i'm still having issues with images in my /images/ folder not displaying (they do if i put them in the /images folder within the theme folder).

I've attached 3 screenshots of the 404, one of the example galleries where the image is not displaying, and the folder structure.

I'd really appreciate it if you could point me in the right direction as to how to resolve this as i'd relly like to use your theme for my site.

Thanks in advance

Richard

On Thu, 6 Jul 2017 at 02:07 Toma Nistor notifications@github.com wrote:

What is your static folder structure? The path to an image in the theme is /images/example-image.jpg.

In the config.toml file, for example, you can use your own logo by changing

logoBig = "/images/osprey-logo.png"

to your own image path.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tomanistor/osprey/issues/6#issuecomment-313267490, or mute the thread https://github.com/notifications/unsubscribe-auth/AJzeAcK2gR9RCUCCfuPzCMS9HP7TftU5ks5sLDM7gaJpZM4ONq3b .

tomanistor commented 7 years ago

Ah yes, I assumed your images folder was inside of the static folder already. Here is the Hugo doc on directory organization: https://gohugo.io/overview/source-directory/

Glad it's working now!