Upgrade to a Git-based workflow
For production use, Doctave recommends a Git-based workflow utilizing docs-as-code. In this section, we'll look at how you can upgrade your documentation workflow from drag and drop uploads to a Git-based workflow.
In a Git-based workflow your site is updated with uploads made from a Git branch, using Doctave's upload script. The script can either be run locally on your machine or integrated into a CI/CD pipeline.
1. Create a new site version
Firstly, create a new version to follow a specific Git branch. To do this,
- Navigate to your site's settings in the Doctave dashboard
- Create a new version
- Set the version to follow a Git branch
This version now follows all uploads that have been initiated by the Doctave upload script in a specific Git branch.
2. Upload your documentation
You can now use the upload script to publish your documentation. Follow our guide to create a new build using the script.
Once you have created a build for your branch, navigate to the builds list page and find the build for your branch and click on the right-hand side to preview it. If everything looks good, you can move forward.
3. Set your new site version as the default version
If your site is public, set the version to be public from the site's settings.
Lastly, you need to set the version to be your site's default version. This will make it the version that's shown to your readers. To do this,
- Navigate to your site's settings in the Doctave dashboard
- Make your version the default version
You're done! Your site is now following uploads made from a Git branch. Next, integrate the script into your CI/CD pipeline to automate your documentation workflow.
Was this page helpful?