{{ $cloud := .Get 0 }}
{{ $js := slice }}
{{ $ts := slice }}
{{ $py := slice }}
{{ $go := slice }}
{{ $cs := slice }}
{{/* Loop through all pages, sorting tutorials for the selected cloud into the appropriate language bucket. */}}
{{ range .Site.Pages }}
{{ if and (hasPrefix .Path (printf "docs/tutorials/%s/" $cloud)) (eq .Params.cloud $cloud) }}
{{ if eq "ts" .Params.language }}{{ $ts = $ts | append . }}{{ end }}
{{ if eq "js" .Params.language }}{{ $js = $js | append . }}{{ end }}
{{ if eq "py" .Params.language }}{{ $py = $py | append . }}{{ end }}
{{ if eq "go" .Params.language }}{{ $go = $go | append . }}{{ end }}
{{ if eq "cs" .Params.language }}{{ $cs = $cs | append . }}{{ end }}
{{ end }}
{{ end }}
Tutorial |
{{ $both := (append $js $ts) }}
{{ if eq (len $both) 0 }}
None for this language. |
{{ else }}
{{ range sort $both ".Params.h1" }}
{{ .Params.h1 }}
|
{{ end }}
{{ end }}
Tutorial |
{{ if eq (len $py) 0 }}
None for this language. |
{{ else }}
{{ range sort $py ".Params.h1" }}
{{ .Params.h1 }}
|
{{ end }}
{{ end }}
Tutorial |
{{ if eq (len $go) 0 }}
None for this language. |
{{ else }}
{{ range sort $go ".Params.h1" }}
{{ .Params.h1 }}
|
{{ end }}
{{ end }}
Tutorial |
{{ if eq (len $cs) 0 }}
None for this language. |
{{ else }}
{{ range sort $cs ".Params.h1" }}
{{ .Params.h1 }}
|
{{ end }}
{{ end }}