That seems OK. Given the amount of time that's passed between starting
the branch and the current master, there might be quite a few merge
conflicts.
I'd suggest trying two things. For each of these I would always use a
new branch in case it goes wrong:
1) Rebase
git checkout karaf && git checkout -b karaf-rebase
git rebase -i HEAD~50
Squash/fixup your commits into manageable/logical blocks (e.g. features;
stuff you might want to revert atomically; etc). See:
https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History#Squashing-Commits
After this is completed, *then* try to rebase onto master (git fetch &&
git rebase remotes/origin/master)
Having fewer commits will make this substantially less work. You may
want to use git rerere:
https://git-scm.com/docs/git-rerere
2) Merge
This might produce something that's a bit messy in terms of history, but
could work. It will squash everything into a single commit, which might
not be as granular as you want.
git fetch && git checkout remotes/origin/master
git merge karaf --squash
Option (1) is probably preferred, but if not possible (2).
FWIW there are a bunch of different patterns you can use. Just two of
them here.
On 08/03/2016 08:21, Charles Moulliard wrote:
On 01/03/16 13:36, Eric Wittmann wrote:
> Hi Charles. Here are some things we would need before we can merge
> the karaf branch:
>
> 1) rebase the karaf branch to master
> 2) squash the commits to a single commit
>> Can you confirm my scenario to rebase and squash ?
git checkout karaf
git rebase master
--> Fix merge issues and commit them ?
git checkout master
git merge --squash
> 3) thorough code review
> 4) testing
>
> #1 - I think this is pretty straightforward.
>
> #2 - Normally I wouldn't mind a small number of commits for a
> contribution like the karaf support, but you've got 221 commits in the
> karaf branch, representing 117 files changed or added. That's a very
> large impact on the project's commit history and will make future
> diffs more difficult than is warranted. So that's the reason to
> squash the commits down to one (or at most a handful).
>
> #3 - I'll need to run through the code with the rest of the apiman dev
> team so we're all familiar with the changes. We need some extra
> eyeballs on the code to make sure we don't (for example) duplicate a
> lot of functionality.
>
> #4 - Obviously we'll need to do some testing to make sure everything
> is working as expected.
>
> Unfortunately we've got a bunch of high priority tasks at the moment,
> so it may be a little while before we can get to #3 and #4. I'm happy
> to accomplish #1 and #2 at some point in the future, although if you'd
> like to give it a try that would be fine too.
>
> -Eric
>
>
> On 3/1/2016 4:13 AM, Charles Moulliard wrote:
>> Hi,
>>
>> Can we consider to merge Karaf branch with Master - trunk ? What are the
>> steps that we have to take care in order to prepare the merge ?
>>
>> Regards,
>>
>> Charles
>> _______________________________________________
>> Apiman-dev mailing list
>> Apiman-dev(a)lists.jboss.org
>>
https://lists.jboss.org/mailman/listinfo/apiman-dev
>>
_______________________________________________
Apiman-dev mailing list
Apiman-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/apiman-dev