farmOS / farmOS.org

Repository for the official farmOS.org website.
https://farmOS.org
10 stars 6 forks source link

301 Redirect /guide/assets/sensors/ to https://v1.farmos.org/guide/assets/sensors/ #53

Closed mstenta closed 2 years ago

mstenta commented 2 years ago

Google Search Console is reporting 404 Not Found on /guide/assets/sensors/, which is an old path from the v1 docs.

This explicitly adds a 301 redirect for that path to the corresponding path on v1.farmos.org.

netlify[bot] commented 2 years ago

Deploy Preview for gracious-brattain-bdd606 ready!

Name Link
Latest commit 5f265365a723580543a86122e489a680192c452a
Latest deploy log https://app.netlify.com/sites/gracious-brattain-bdd606/deploys/63500207d8c59200089bd835
Deploy Preview https://deploy-preview-53--gracious-brattain-bdd606.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

mstenta commented 2 years ago

I'm curious if this change will work, considering that we also already have a redirect from /guide/assets/* to /guide/assets/ so I don't know if that will take precedence. Hopefully the Netlify preview will give us the chance to test it.

https://github.com/farmOS/farmOS.org/blob/c1346734736aa4fef9d6efb73cb964db4e26fe93/static/_redirects#L9

mstenta commented 2 years ago

Huh. Doesn't seem to work. And in fact it also seems that the existing redirect (https://github.com/farmOS/farmOS.org/blob/c1346734736aa4fef9d6efb73cb964db4e26fe93/static/_redirects#L9) isn't working as intended either... in neither the preview nor farmOS.org.

jgaehring commented 2 years ago

Would it be easier just listing each page individually, rather than using the wildcard? I know it's a lil annoying, but there aren't that many, and there shouldn't be a need to add more redirects over time, right?

so I don't know if that will take precedence. Hopefully the Netlify preview will give us the chance to test it.

https://docs.netlify.com/routing/redirects/#rule-processing-order

mstenta commented 2 years ago

Yea that makes sense. :+1:

mstenta commented 2 years ago

I'll start a new PR to try that...