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

BREAKING CHANGE: fix Hugo's .Site.IsServer error #375

Merged
merged 1 commit into from
Aug 20, 2024

Conversation

Vimux
Copy link
Owner

@Vimux Vimux commented Aug 20, 2024

As of Hugo 0.120.0, .Site.IsServer is deprecated, and starting with Hugo 0.132.0, it causes a build error. Unfortunately, this is a breaking upstream change that we can't "fix" on our end. As a result, we had to raise the minimum supported version to v0.54.0 and implement another workaround to ensure compatibility with older versions, not just Hugo v0.120.0 and all subsequent versions.

Warning

This change requires manual intervention if you are using the Mainroad theme with older versions of Hugo v0.48 - v0.53. Please upgrade Hugo.

Changes:

  • Fix .Site.IsServer deprecation error
  • Raise the minimum supported version to Hugo v0.54.0
  • Update documentation
  • сi-test.yml: Add 0.132.0 to the cursed list

Unlike Hugo, we avoid breaking our code annually without a compelling reason. Unfortunately, there are more and more such upstream changes.

Fix #369

As of Hugo 0.120.0, `.Site.IsServer` is deprecated, and starting with Hugo 0.132.0, it causes a build error. Unfortunately, this is a breaking upstream change that we can't "fix" on our end. As a result, we had to raise the minimum supported version to v0.54.0 and implement another workaround to ensure compatibility with older versions, not just Hugo v0.120.0 and all subsequent versions.

Fix #369
@Vimux Vimux merged commit 86f1b19 into master Aug 20, 2024
11 checks passed
@Vimux Vimux deleted the fix-is-server-deprecation-error branch August 20, 2024 16:00
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 this pull request may close these issues.

Deprecated .Site.IsServer causing build WARNING (ERROR in v0.133.0)
1 participant