{{ $scratch := newScratch }} {{ $productPathData := findRE "[^/]+.*?" .RelPermalink }} {{ $product := index $productPathData 0 }} {{ $currentVersion := index $productPathData 1 }} {{ if or (eq $product nil) (lt (len (findRE `v[0-2]\.[0-9x]{1,2}` $currentVersion)) 1) }} {{ else }}
{{ cond (in $currentVersion "v") $currentVersion (title $currentVersion) }}