#Docs versioning question

1 messages · Page 1 of 1 (latest)

crimson lion
#

I saw that we have a random prefix for each markdown file created via new.sh

#

I'd like to understand this system more - what is its purpose? Is it for versioning?

#

@vast kestrel ^^

#

Docs versioning question

spark quarry
#

It’s to give each article a unique ID and url, regardless of its position in the structure of the docs

#

makes it easier to change the overall structure without ever breaking links

crimson lion
#

would it be fair to say that the overall structure could change only between different dagger versions?

spark quarry
#

Not necessarily

#

But that’s a common reason

#

another reason would be a refactoring of the docs based on new ideas on the best learning experience

#

or terminology changes

crimson lion
#

OK, I see

#

For example, I see we are using the sidebar versioning suggested in the above link, just curious why we aren't also versioning the content the same way

spark quarry
#

It’s inspired by the tailscale docs

#

basically every article is a unique knowledge base entry

#

decoupled from narrative structure

#

the decoupling is the valuable part

#

At the time we had decided not to use docusaurus versioning for the time being, for an unrelated reason that I don’t remember . @lunar panther and @rotund siren are the best people to ask

#

I think those two things (docusaurus versioning and article IDs) can co exist peacefully but I don’t know for sure

crimson lion
#

So this means that when the cloak branch is merged into main, the docs for 0.2 and 0.3 will co-exist in the same folder eg. guides will contain guides for 0.2 and 0.3 together, and the 0.2 and 0.3 sidebar JS will provide the "map" as to which guide goes with each version?

#

I guess that we are also building the docs for 0.1 every time we build the docs for 0.2 as well? Probably not a major concern at this point but the process could be optimized slightly: if there are no changes being made to 0.1 docs any longer, they could be built once as a static sub-site and then removed from the regular build cadence. However this would require using the docusaurus versioning approach and plugin. TBD.

sterile prawn
#

The easiest tool so far I found which delivers versioned documentation is Antora.org, with each version pulled from a tag or branch. It requires to switch the content type to Asciidoc. Personally, I find this a better markup standard dan Markdown.

crimson lion
sterile prawn
lunar panther
crimson lion
#

OK thanks

crimson lion
#

"For instance https://docs.dagger.io/1003/get-started/ would become https://docs.dagger.io/1.0/1003/get-started/" -> but wouldn't this be the correct behaviour? ie. if product v1.0 differs from v2.0, then the 1.0 get-started would presumably also differ from the 2.0 get-started. Therefore there should be a new (valid for v2.0) get-started at the original URL https://docs.dagger.io/1003/get-started/ when product v2.0 is released. The URL should not break.

(I feel like I have misunderstood something here but not sure what exactly.)

#

Also in the GH ticket I saw there was a proposal to have "a snapshot of docs 0.1.
Then we'll remove all 0.1 docs from our current repo to avoid confusion between the two versions.". This makes a lot of sense to me. However I couldn't understand from the ticket if this was finally implemented or not?

lunar panther
lunar panther
crimson lion
#

Regarding the link https://docs.dagger.io/1010/dev-cue-package/ which would throw a 404: I would argue this is not really such a big issue - assuming that most people will over time migrate to the new version, this page will become less and less useful. If the page continues to see a lot of traffic and the 404 is creating issues, we can always avoid the 404 by adding a redirect to the new versioned URL.

I noticed that even with the current solution, where the link remains active, a user visiting it sees a somewhat broken site (see the screenshot sidebar).

If we use a fixed versioning scheme, then all links will always be of the form docs.dagger.io/version/slug, so even when moving the docs to a new version, old links will continue to work - therefore this seems like it would solve the problem for all future versions?

Note I'm not advocating that we should do this necessarily, just that I can definitely see some advantages to this approach.

crimson lion