docs/build-pieces/misc/private-fork.mdx
By following these steps, you can create a private fork on GitHub, GitLab or another platform and configure the "activepieces" repository as the upstream source, allowing you to incorporate changes from the "activepieces" repository.
Begin by creating a bare clone of the repository. Remember that this is a temporary step and will be deleted later.
git clone --bare [email protected]:activepieces/activepieces.git
Generate a new private repository on GitHub or your chosen platform. When initializing the new repository, do not include a README, license, or gitignore files. This precaution is essential to avoid merge conflicts when synchronizing your fork with the original repository.
Mirror-push the bare clone you created earlier to your newly created "activepieces" repository. Make sure to replace <your_username> in the URL below with your actual GitHub username.
cd activepieces.git
git push --mirror [email protected]:<your_username>/activepieces.git
cd ..
rm -rf activepieces.git
Now, you can clone your "activepieces" repository onto your local machine into your desired directory.
cd ~/path/to/directory
git clone [email protected]:<your_username>/activepieces.git
If desired, you can add the original repository as a remote to fetch potential future changes. However, remember to disable push operations for this remote, as you are not permitted to push changes to it.
git remote add upstream [email protected]:activepieces/activepieces.git
git remote set-url --push upstream DISABLE
You can view a list of all your remotes using git remote -v. It should resemble the following:
origin [email protected]:<your_username>/activepieces.git (fetch)
origin [email protected]:<your_username>/activepieces.git (push)
upstream [email protected]:activepieces/activepieces.git (fetch)
upstream DISABLE (push)
When pushing changes, always use
git push origin.
To retrieve changes from the "upstream" repository, fetch the remote and rebase your work on top of it.
git fetch upstream
git merge upstream/main
Conflict resolution should not be necessary since you've only added pieces to your repository.