Live data from Hacker News

Migrating from Jekyll to Hugo

dannyguo.com

21–30 of 92 posts

Re: Migrating from Jekyll to Hugo

#21
I'm in the process of creating a new blog and site (I have python, vue, nuxt background) which maybe will have more non technical authors and dynamic content in the future and after many iterations (looking deeply at Hugo, Lektor, Forestry and even Wordpress [headless]) I will probably go to a

open source headless CMS Strapi https://strapi.io and Nuxt.js frontend.

If anybody knows a python and flask based headless CMS let me know!

Re: Migrating from Jekyll to Hugo

#22
post #14

I feel like people spend more time migrating blogging engines than actually blogging.

At least then you can blog about the blogging engine migration.

I personally enjoy the grand tradition of nerds writing blogs only about how they set up a blog.

Re: Migrating from Jekyll to Hugo

#23
post #20

Earlier quoted context omitted.

Having few assets is better than having a fancy asset pipeline. https://www.gatsbyjs.org/ supports code splitting and since it uses JavaScript, CSS generation libraries like styled-components, Glamourous, and JSS are available. That means only outputting the CSS and JS that are needed for the page. This is great for blogs where someone might only read one article. The Hugo community is working toward minimal assets t…

> Having few assets is better than having a fancy asset pipeline. It's not about a fancy asset pipeline. It's taking app.css and turning it into app.a5fec617.css so that you can configure your web server to cache it forever. It's important to do this for CSS, JS and all of your images and other assets. Each blog post of mine has a cover image and with 170 blog posts, that's 170 blog images that need to be md5 tagged.…

Without md5 tagging but with a reasonably configured web server, the browser gets an eTag in the response headers to the first request to load that cover image, and sends it in the headers to the second request and gets a 304 Not Modified response with an empty body. The size of the cover image is completely moot when comparing a proper Hugo config vs a proper asset pipeline config.

Re: Migrating from Jekyll to Hugo

#24
FWIW, I achieved something like live reloading in Jekyll using an additional config file.

_config_local.yml:

    html_refresh: true
    html_refresh_rate: 5
Then, I appended the config via:

    jekyll serve --config _config.yml,_config_local.yml --force-polling
And then did a check in my header include:

    {% if site.html_refresh %}
      
    {% endif %}
You can find a working example in my blog's repo[1].

[1]: https://github.com/woodruffw/blog

Re: Migrating from Jekyll to Hugo

#25
We’re running our blog on Jekyll. Is there any good reason to migrate to Hugo? In the article I’ve found this comment:

Hugo’s key differentiators: 1. Ease of install 2. Speed (critical for large sites) 3. Integrated live-reload while editing in near realtime 4. Multilingual capabilities 5. Flexible 6. Very strong community 7. Very good & comprehensive documentation (but not perfect…yet)

Other than 3., all other points are valid for Jekyll as well. So why move, other than for the sake of just migrating (which can be fun too...)?

Re: Migrating from Jekyll to Hugo

#26
I have an interesting Jekyll performance story. I was trying to build a website [1] that was going to be the new destination for git information. The site is a static site and I figured that since Jekyll was integrated into GitHub, it would be simple. My script downloaded all of the git documentation from the linux kernel website, did some parsing of the HTML files adding front matter, and then tried to generate the site.

My Jekyll(Ruby) script was running over a day and never finished. Hugo(Go) ran in about 5 minutes. Granted there are over 10,000 pages being generated by Jekyll but it was so painfully slow, I couldn't possibly have a daily CI system that generated the site.

I'm still fixing some https issues with GitHub static site hosting, but it should be working soon.

[1] - https://github.com/dvcs/gitdvcs.com

Re: Migrating from Jekyll to Hugo

#27
post #25

We’re running our blog on Jekyll. Is there any good reason to migrate to Hugo? In the article I’ve found this comment: Hugo’s key differentiators: 1. Ease of install 2. Speed (critical for large sites) 3. Integrated live-reload while editing in near realtime 4. Multilingual capabilities 5. Flexible 6. Very strong community 7. Very good & comprehensive documentation (but not perfect…yet) Other than 3., all other point…

I'm not sure you understand. That quote is not listing Hugo's limitations, but rather it's strengths compared to Jekyll.

Re: Migrating from Jekyll to Hugo

#28

I feel like people spend more time migrating blogging engines than actually blogging.

I did that for a while.

I used Ghost, Octopress (which was basically Jekyll), a variety of SSGs that I tested and never got to deploying, and then Pelican.

Since January 2016, though, infrastructure work basically stopped and I just write things, and occasionally dink the theme.

Re: Migrating from Jekyll to Hugo

#30
post #20

Earlier quoted context omitted.

> Having few assets is better than having a fancy asset pipeline. It's not about a fancy asset pipeline. It's taking app.css and turning it into app.a5fec617.css so that you can configure your web server to cache it forever. It's important to do this for CSS, JS and all of your images and other assets. Each blog post of mine has a cover image and with 170 blog posts, that's 170 blog images that need to be md5 tagged.…

Without md5 tagging but with a reasonably configured web server, the browser gets an eTag in the response headers to the first request to load that cover image , and sends it in the headers to the second request and gets a 304 Not Modified response with an empty body. The size of the cover image is completely moot when comparing a proper Hugo config vs a proper asset pipeline config.

The main advantage of a hash is that browsers will download the new version of your CSS/JS on the next page view, while still caching it «forever»

If the url stays the same, you never know what version your visitors will get. You might publish a new version, but the user would not see it due to browser caches or proxies.

Post reply on HN