付费用户可以使用现成的方案,地址见 链接

但是私有gitlab时候,需要手动进行如下操作

1. Clone your fork:

git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream

3. Updating your fork from original repo to keep up with their changes:

git pull upstream master

原文操作见链接
更多相关链接
https://stackoverflow.com/questions/3903817/pull-new-updates-from-original-github-repository-into-forked-github-repository/3903835#3903835
https://help.github.com/en/articles/fork-a-repo gitlab和github 在这方面上还是有些不同,github会自动同步,可以节约很多时间
05-18 05:48