Ho guys!

I made a scripted manual rebase of each commit (basically add the commit
not via its diff, but such that it reflects the code base after the commit)

https://github.com/StephanEwen/incubator-flink/commits/streamrebase

No more merge commits that mess things up. You should be able to squash
things easily via "git rebase -i 3002258f8a22a8adbdb230e57c972ad17910debf"

The commit diffs may be a bit different than before (not too much if I did
things correctly), but can you have a quick look at the commits to see
whether they make sense?

Stephan


BTW: I used this way to do it:

Have two repositories (clones)
  - /data/repositories/flink
  - /data/repositories/flinkbak

The do the following for every non-merge commit:
 - Check out the state after a commit in the backup (detached head)
 - Remove current streaming directory (physically and from the index)
 - Add it again (files and index), with the state of the cloned repo
 - Commit (git recreates the diffs in a way that they reflect the original
commit plus any merges)

---------------------

#!/bin/bash

for line in $(cat commits)
do
  cd /data/repositories/flinkbak
  author=`git --no-pager show -s --format='%an <%ae>' $line`
  message=`git --no-pager show -s --format='%s%n' $line`

  echo "picking commit $line from author $author"

  git checkout $line
  cd /data/repositories/flink
  rm -rf "/data/repositories/flink/flink-addons/flink-streaming"
  git rm -r "/data/repositories/flink/flink-addons/flink-streaming"
  cp -r "/data/repositories/flinkbak/flink-addons/flink-streaming"
"/data/repositories/flink/flink-addons/flink-streaming"
  git add /data/repositories/flink/flink-addons/flink-streaming
  git commit --author "$author" --m "$message"

#  read -rsp $'Press any key to continue...\n' -n1 key
done





On Mon, Jul 14, 2014 at 1:10 PM, Gyula Fóra <[email protected]> wrote:

> By the way, I forked your repo switch to the streaming branch and then I
> executed the commands (I think this is how it should have been done)
>
>
> On Mon, Jul 14, 2014 at 1:09 PM, Gyula Fóra <[email protected]> wrote:
>
>> This is what I get with "rebase -i -p master":
>>
>> pick 9456624 Merge branch 'master' of file:///data/repositories/streamin
>> into streaming
>> pick 89299b8 [streaming] Post-merge cleanups
>>
>> #Rebase 1fd457d..89299b8 onto 1fd457d
>> #......
>>
>>
>> On Mon, Jul 14, 2014 at 12:47 PM, Stephan Ewen <[email protected]> wrote:
>>
>>> Can you do "rebase -i -p master". That should include all commits and
>>> might save you the meeting hell.
>>>
>>
>>
>

Reply via email to