Commits (2)
  • Jamie Tanna's avatar
    Create a Netlify redirect for Hugo Aliases · 017a2aa3
    Jamie Tanna authored
    As part of jvt.me#703, I want to be redirecting these using HTTP 301s,
    rather than using a client-side redirect, as then it's not going to be
    cached, and will impact SEO.
    
    This generates 301s for each and every alias on the site, and the `!`
    indicates to redirect whether something else matches that path or not,
    as it'd be matched by Hugo's built-in aliases, which we'll leave
    enabled.
    017a2aa3
  • Jamie Tanna's avatar
    Merge branch 'feature/netlify-aliases' into 'fork' · ab9aaae8
    Jamie Tanna authored
    Create a Netlify redirect for Hugo Aliases
    
    See merge request !128
    ab9aaae8
https://jamietanna.co.uk/* {{.Site.Params.liveSiteUrl}}/:splat 301!
https://www.jamietanna.co.uk/* {{.Site.Params.liveSiteUrl}}/:splat 301!
{{ range $p := $.Site.RegularPages -}}
{{ range .Aliases }}
{{ . | printf "%-35s" }} {{ $p.RelPermalink -}} 301!
{{ end -}}
{{- end -}}