git - 如何自动对齐/同步一个 fork 的 Github origin/master 分支到 upstream/master?

标签 git github version-control repository git-fork

有没有办法自动同步我的forked Github 存储库的远程主分支(origin/master)到原始 Github 仓库的 master 分支? (上游/主控)

我问是因为我希望我在 Github 上的 fork remote origin/master 分支始终保持最新状态,这样我就可以节省时间不断地 pull /rebase & push 上游存储库更改到我的 fork 存储库的主分支。

最佳答案

同步分支存储库非常容易,但问题是如何同步?

在这个例子中我使用了WorldMapGenerator Repository

Go to your forked repository, you can see setting button click on it.

enter image description here

After clicking on setting button you can see Webhooks & services option in left menu click on it.

enter image description here

Then you can see Add Webhook Button on right side just click on it.

enter image description here

After clicking Add Webhook Button, details page will get open, so in detail page yo can see payload url. Enter http://backstroke.us url in it.

enter image description here

现在,如果任何提交进入主仓库,那么 pull 请求将进入您的 fork 仓库。

就是这样享受:)

更多详情https://github.com/1egoman/backstroke

关于git - 如何自动对齐/同步一个 fork 的 Github origin/master 分支到 upstream/master?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28639713/

相关文章:

git - 在 SourceForge 上强制 Git 推送

svn - 从 git 还是 svn 开始?

Git - 如何查找目录中所有项目的所有 "unpushed"提交?

git - 如何知道是否有正在进行的 git rebase?

git - GitHub 上托管的 Intellij 项目显示为颠覆项目?

github - 在 github-flavored-markdown 中对齐图像

linux - 无法安装git

database - 将更改从开发数据库传输到生产数据库

python - CVS 或 SVN 有哪些 Python 绑定(bind)?

git - 如何进行git克隆并进入创建的目录