mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2024-11-23 07:47:54 +00:00
shortcodes: fix Hugo version check
This commit is contained in:
parent
7daec21538
commit
5fd3fdbd75
4 changed files with 4 additions and 4 deletions
|
@ -2,7 +2,7 @@
|
|||
{{- $major := int (index $version 0) }}
|
||||
{{- $minor := int (index $version 1) }}
|
||||
{{- $id := "" }}
|
||||
{{- if and (ge $major 0) (ge $major 108) }}
|
||||
{{- if or (and (eq $major 0) (ge $minor 108)) (gt $major 0) }}
|
||||
{{- $id = .Ordinal }}
|
||||
{{- end }}
|
||||
{{- partial "shortcodes/image.html" (dict
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
{{- $major := int (index $version 0) }}
|
||||
{{- $minor := int (index $version 1) }}
|
||||
{{- $id := "" }}
|
||||
{{- if and (ge $major 0) (ge $major 108) }}
|
||||
{{- if or (and (eq $major 0) (ge $minor 108)) (gt $major 0) }}
|
||||
{{- $id = .Ordinal }}
|
||||
{{- end }}
|
||||
{{- partial "shortcodes/expand.html" (dict
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
{{- $major := int (index $version 0) }}
|
||||
{{- $minor := int (index $version 1) }}
|
||||
{{- $id := "" }}
|
||||
{{- if and (ge $major 0) (ge $major 108) }}
|
||||
{{- if or (and (eq $major 0) (ge $minor 108)) (gt $major 0) }}
|
||||
{{- $id = .Ordinal }}
|
||||
{{- end }}
|
||||
{{- partial "shortcodes/openapi.html" (dict
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
{{- $major := int (index $version 0) }}
|
||||
{{- $minor := int (index $version 1) }}
|
||||
{{- $id := "" }}
|
||||
{{- if and (ge $major 0) (ge $major 108) }}
|
||||
{{- if or (and (eq $major 0) (ge $minor 108)) (gt $major 0) }}
|
||||
{{- $id = .Ordinal }}
|
||||
{{- end }}
|
||||
{{- partial "shortcodes/swagger.html" (dict
|
||||
|
|
Loading…
Reference in a new issue