-
Notifications
You must be signed in to change notification settings - Fork 314
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Protocol notes don't actually deploy multiple versions #6
Comments
A setup that would be really useful for development would be:
This way, it would be possible to preview notes or API documentation of in-progress work. I think this should be possible with Github Actions, but it might require changes to the hosting in order to be able to make partial updates and deletions, since the firebase cli only performs atomic updates. S3+Cloudfront or something would probably work just as well. |
We haven't done this in the last year and a half and things have worked out, so we can probably skip it. |
Modifies the firebase hosting config to remove the `/<version>/` prefix from the guide URLs, which has only ever been `/main/`, due to #6. Also includes rewrites so that historical URLs with the `/main/` prefix will still be honored, and redirected to the appropriate location that's live in the docs. Squirreling away this one-liner for generating a "sitemap" of all URLs: curl -s http://localhost:5000 \ | rg -i 'class="chapter"' \ | perl -npE 's/href=/\nhref=/g ' \ | perl -nE '/href="([\w.\/]+)"/g and say $1' > sitemap.txt which was helpful in creating the redirects. Removes the mdboook-only meta-refresh redirects added in #4232, because the browser UX was atrocious. Refs #3417.
Modifies the firebase hosting config to remove the `/<version>/` prefix from the guide URLs, which has only ever been `/main/`, due to #6. Also includes rewrites so that historical URLs with the `/main/` prefix will still be honored, and redirected to the appropriate location that's live in the docs. Squirreling away this one-liner for generating a "sitemap" of all URLs: curl -s http://localhost:5000 \ | rg -i 'class="chapter"' \ | perl -npE 's/href=/\nhref=/g ' \ | perl -nE '/href="([\w.\/]+)"/g and say $1' > sitemap.txt which was helpful in creating the redirects. Removes the mdboook-only meta-refresh redirects added in #4232, because the browser UX was atrocious. Refs #3417.
#5 changes the protocol notes so that there's a version field included in the URL paths. This way, in the future, there can be a separately-rendered set of docs for each tag or branch.
However, the current deploy pipeline uses the firebase cli, which only does atomic deployments, so there's no way to add a set of files to the existing site, and this means that only the most recently deployed version will actually appear. At the moment this isn't a big deal because there's just one version anyways.
The text was updated successfully, but these errors were encountered: