Skip to content
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

feat(website): enable docs versioning #5676

Merged
merged 7 commits into from
Dec 25, 2018

Conversation

ikatyang
Copy link
Member

Fixes #5362 (by upgrading docusaurus)
Unblock #5674

v1 docs are generated by yarn docusaurus-version v1, which enables the docs versioning and copies the current docs to the v1 folder. We just need to run it again to sync the current docs and the next docs before releasing a new version.

cc @kachkaev

  • I’ve added tests to confirm my change works.
  • (If changing the API or CLI) I’ve documented the changes I’ve made (in the docs/ directory)
  • I’ve read the contributing guidelines.

Try the playground for this PR

@ikatyang
Copy link
Member Author

ikatyang commented Dec 22, 2018

I forgot the version field in package.json is changed after yarn build(fixed). Here's the expected output for https://deploy-preview-5676--prettier.netlify.com/versions.html:

image

@ikatyang ikatyang added the status:wip Pull requests that are a work in progress and should not be merged label Dec 22, 2018
@ikatyang ikatyang removed the status:wip Pull requests that are a work in progress and should not be merged label Dec 22, 2018
Copy link
Member

@j-f1 j-f1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think about calling it stable instead of v1? Once we release v2, the docs will then be available as stable, 1.x and next.

website/pages/en/versions.js Outdated Show resolved Hide resolved
website/pages/en/versions.js Outdated Show resolved Hide resolved
@j-f1
Copy link
Member

j-f1 commented Dec 22, 2018

Also, how will the docs be updated when releasing a new version?

@kachkaev
Copy link
Member

Thanks for working on this @ikatyang and for cc-ing me! I don't have any experience with docusaurus or publishing several doc versions at once, so unfortunately can't express any useful opinion here. If using a single master branch and multi-versioned docs works well as multiple branches we were discussing in #5671, I'm happy with this decision.

@ikatyang
Copy link
Member Author

Based on the discussion in #5671, I think it should be better to be in this form:

This PR aims to address stable and next minor, the major ones should be handled in v2.

@ikatyang ikatyang added the status:wip Pull requests that are a work in progress and should not be merged label Dec 23, 2018
@ikatyang
Copy link
Member Author

Also, how will the docs be updated when releasing a new version?

yarn docusaurus-version <version-id> is the command to take a snapshot for the current docs for docs versioning, so we just need to run yarn docusaurus-version stable again to override stable with next (master).

@ikatyang ikatyang removed the status:wip Pull requests that are a work in progress and should not be merged label Dec 23, 2018
@ikatyang ikatyang merged commit f744a84 into prettier:master Dec 25, 2018
@ikatyang ikatyang deleted the chore/website-version branch December 25, 2018 00:20
@lock lock bot added the locked-due-to-inactivity Please open a new issue and fill out the template instead of commenting. label Mar 25, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Mar 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
locked-due-to-inactivity Please open a new issue and fill out the template instead of commenting.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants