将远程存储库提交合并到本地 [英] Merge remote repository commits to the local
问题描述
我有两个使用 C ++ Poppler 库的远程存储库,例如 A(original-poppler)
和 B(另一个-poppler)
。第二个 B
存储库的主要含义是为某些Linux发行版维护 Poppler 库并为它们构建rpm包。
从这个 我怎样才能将 B
是通过复制文件从 A
创建的 - 我看到第一个提交移植的最新版本
和许多提交的文件 - 它应该来自一些 A
提交(版本 0.20 <
变更(补丁)
$ b Ported latest version开始
repository B
终其一生 - 添加了一些补丁,更新了规范文件等。
A
版本库已更新为版本 0.23.1(发行版)
+之后的一些其他提交。
我可以克隆两个存储库并将更改推送到 B
。
B
存储库更新为 0.23.1
的完全版本(没有未发布的提交) c $ c> B
请给我最好的可维护解决方案。 $ b
- 使分支releaseA跟踪A中的发布分支一个分支releaseB跟踪B中的发布分支
- 通过从每个存储库中提取更新两个分支。
- 签出releaseB
- 将releaseA合并为releaseB
- 推送至B
I have two remotes repositories with C++ Poppler library, say A (original-poppler)
and B (another-poppler)
. The main meaning of second B
repository is maintaining Poppler library for some Linux distro and building for them rpm packages.
B
was created from A
just by copying files - I see the first commit Ported latest version
and many committed files - it should be from some A
commit (version 0.20
).
Starting from this "Ported latest version"
repository B
lives his life - are added some patches, updated spec files, etc.
A
repository was updated to the version 0.23.1 (release)
+ some other commits after that.
I can clone both repositories and push changes to the B
.
How can I update this B
repository up to the 0.23.1
exactly version (without non-released commits) with respect for B
changes (patches)?
Give me please the best maintainable solutions.
- Make a branch "releaseA" tracking the release branch in A
- Make a branch "releaseB" tracking the release branch in B
- Update both branches by pulling from each repository.
- Checkout "releaseB"
- Merge "releaseA" into "releaseB"
- Push to B.
这篇关于将远程存储库提交合并到本地的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!