GitHub 2-way sync
GitHub's 2-way sync feature allows for a bidirectional synchronization between GitHub repositories and Archbee. Unlike a traditional one-way sync, which only updates changes from a source to destination (Github to Archbee), 2-way sync ensures that changes made in both GitHub and Archbee are reflected on each platform.
Even though this is a 2-way sync system, we still consider GitHub as the absolute source of truth. We will open a PR, and whether you merge that request is up to you. Note that if you do merge it, the documents in Archbee will get updated.
Whether you're a developer, project manager, or collaborator, this feature allows you to seamlessly synchronize your GitHub repositories with Archbee, ensuring consistency across your workflows.
To enable the 2-way sync on your Archbee account, follow these steps:
- After the setup is done, you will be redirected to the Configurations page, and you should see the GitHub is connectedstatus.
When you create a new Space, you can select a repository from the Write in GitHub option.
Select your Git repository and the branch you want to import and click Add Space at the bottom of the modal:
Once completed, you should receive a notification that your GitHub content has been imported.
In the Archbee Editor, click on the Edit in GitHub button and you will be redirected to your GitHub account.
Make your edits.
Click on Commit changes when ready.
Go back to Archbee. After you receive the notification in the lower right corner, the content should update in real-time.
In the Archbee editor, click on the Edit button and the review system will be activated for your space.
Write/replace your content in Draft mode.
Once you've completed this, go to Publish Space in the top right corner. Select Push to Github Pull Request, and then Review & Push to Gitbub PRs to review.
Review your changes and if it's all good, hit the Push to GitHub PR button.
Use the Push to GitHub Pull Request button to open the pull request in your GitHub repository:
Review the changes in the GitHub repository.
Click on Merge Pull request -> Confirm Merge.
Go back to Archbee. Content will be updated in GitHub as soon as you receive this successful notification:
To initiate the sync process, you need to select the specific branch in your GitHub repository that Archbee will monitor for changes. Subsequently, you need to open pull requests in this designated branch to trigger the sync mechanism.
If that doesn't work automatically, you can force sync by navigating to Space settings > GitHub integration > click the Sync with repo button.