De-index old versions manually with robot meta tags#444
Conversation
napari/docs#364 This is a one-shot fix for versions prior to html_baseurl being added to napari/docs config.py. Script used ```bash STABLE=$(readlink stable) for d in */; do case "${d%/}" in stable|"$STABLE"|dev|_*) continue;; esac find "$d" -name '*.html' -exec sed -i '' -e 's|<head>|<head>\ <meta name="robots" content="noindex,follow">|' {} + done ``` Assisted-By: Claude
|
I think this broke github, there are in fact 8294 files changed and not zero... |
|
@Yann-P thank you again for the full circle fix! I gotta agree with my college students on this one, searching is absolutely not leading me to anything useful ... just regurgitated AI slop websites or vague forum posts. Edit: YAY I think I found the actual documentation now.... https://developers.google.com/search/docs/crawling-indexing/robots-meta-tag In reading what I can it seems like |
|
In my understanding "nofollow" tells Google to not trust these links / mark them as not controlled by us. Noindex should be enough |
|
As I wrote in napari/docs#1029, I think we should try to just merge the If it is, I suggest you use the claude-generated script in the PR description locally and push instead of merging this PR that is already drifting out-of-date and that Github can't handle anyway because of its size. Moreover I wonder if a robots.txt like this one would work if we want to hard-deindex all old versions. |
|
OR we create a robots.txt for all existing versions of napari and let the canonical tag do its job for all future versions of napari |
# References and relevant issues <!-- What relevant resources were used in the creation of this PR? If this PR addresses an existing issue on the repo, please link to that issue here as "Closes #(issue-number)". If this PR adds docs for a napari PR please add a "Depends on <napari PR link>" --> #364 # Description <!-- What does this pull request (PR) do? Does it add new content, improve/fix existing context, improve/fix workflow/documentation build/deployment or something else? <!-- If relevant, please include a screenshot or a screen capture in your content change: "An image is worth a thousand words!" --> <!-- You can use https://www.cockos.com/licecap/ or similar to create animations. --> <!-- You can also see a preview of the documentation changes you are submitting by clicking on "Details" to the right of the "Check the rendered docs here!" check on your PR.--> Set html_baseurl which translates to canonical to point to the stable version. However, for this to be effective we need to set noindex as suggested on #364, which is what I did in this additional pull request: napari/napari.github.io#444 <!-- Previewing the Documentation Build When you submit this PR, jobs that preview the documentation will be kicked off. By default, they will use the `slimfast` build (`make` target), which is fast, because it doesn't build any content from outside the `docs` repository and doesn't run notebook cells. You can trigger other builds by commenting on the PR with: @napari-bot make <target> where <target> can be: html : a full build, just like the deployment to napari.org html-noplot : a full build, but without the gallery examples from `napari/napari` docs : only the content from `napari/docs`, with notebook code cells executed slimfast : the default, only the content from `napari/docs`, without code cell execution slimgallery : `slimfast`, but with the gallery examples from `napari/napari` built --> <!-- Final Checklist - If images included: I have added [alt text](https://webaim.org/techniques/alttext/) If workflow, documentation build or deployment change: - My PR is the minimum possible work for the desired functionality - I have commented my code, to let others know what it does --> Co-authored-by: Tim Monko <timmonko@gmail.com>
|
Closing in favor of waiting an and a tracking issue #445 |
napari/docs#364
This is a one-shot fix for versions prior to
html_baseurlbeing added tonapari/docs'sconfig.pynapari/docs#1029.Script used
Assisted-By: Claude (to generate the script). I checked that no stable docs contain nofollow (0.7.0).