I have forked a repo for adding some changes to the project; its a Vim plugin. I am planning to use my forked repo as the source for Vundle. But I would also like to get updates from the original repo if any in the future.
How should I go about maintaining the repo?
note:
If you're improving the plugin, the best solution might be to propose your patch to the owner of the original repo.
If you can't or don't want to do it, you could either keep it in a dev branch or in your master
. It won't make any difference: either way you'll have to do a merge between your branch and origin/master
every time you'll want to retrieve update from upstream.
Example: let's assume you want to keep it on your local master
branch. Then you would have:
A ----------------- B
L origin/master L master
where B
is the commit you made with your modifications.
When you want to retrieve updates from upstream, using git fetch origin
, you would end up with:
---- B
/ L master
/
A -- C -- D
L origin/master
Then you'd just need to do, from your master
branch: git merge origin/master
, in order to get a commit with both your modifications and the updates
---- B -- E
/ /L master
/ /
A -- C -- D
L origin/master
As we can see, it would be easier if your changes could be accepted upstream. Not only could anyone benefit from it; it would also be much easier for you.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.