<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Thx. I will work on that this Tuesday <br>
    <br>
    On 16/03/16 15:23, Rachel Yordan wrote:<br>
    <blockquote
cite="mid:CAM=PQa0dgGU6gP_kFeTEJTjiMAA3g8ZUTDWMAveP09E-xhKLiA@mail.gmail.com"
      type="cite">
      <div dir="ltr">Marc is definitely the git surgeon here, whereas
        I'm more of a git butcher.
        <div><br>
        </div>
        <div>But I'll just say that I typically try to avoid rebasing
          the branch commits against master. If you'd still prefer to
          rebase branch against master then I would check out an
          entirely new branch based off of master and use that for the
          karaf rebase. Actually, I'd do that either way. I'd do the
          following:
          <div><br>
          </div>
          <div>1. Make sure your master branch is up to date:</div>
          <div>$ git checkout master</div>
          <div>$ git pull upstream master</div>
          <div><br>
          </div>
          <div>2. Check out a branch based off of master in case all
            goes to hell:</div>
          <div>$ git checkout -b master-2</div>
          <div><br>
          </div>
          <div>3. Go back to the karaf branch and get an idea of how
            many commits you have vs. master (looks like around 221
            judging by <a moz-do-not-send="true"
              href="https://github.com/apiman/apiman/compare/karaf?expand=1">this</a>):</div>
          <div>$ git checkout karaf</div>
          <div>$ git rev-list --count HEAD ^master-2</div>
          <div><br>
          </div>
          <div>4. Rebase against the new master-2 branch:</div>
          <div>$ git rebase -i HEAD~221</div>
          <div><br>
          </div>
          <div>* May not actually be 221, replace with the number you
            get in step 3.</div>
          <div><br>
          </div>
          <div>Surely you know this already, but in the event that it
            helps here are some vim tips:</div>
          <div>
            <ul>
              <li>Enter interactive mode by typing `I` and only leave
                the first commit as `pick`, type `s` or `squash` for the
                rest. You can also use `f` or `fixup` if you don't want
                to include the commit message.<br>
              </li>
              <li>Save and quit by typing `wq!` and pressing enter.
                You'll probably have to repeat this.</li>
              <li>If you get stuck or want to quit without saving
                (completely cancel the rebase), just press Esc to exit
                interactive mode on vim and type `:%d|x`, then press
                enter.</li>
            </ul>
          </div>
          <div>Once you're done, you may want to change the commit
            message for that single commit, so you'd just do `git commit
            --amend -m "Blah blah"`. You'll probably have to do `git
            push origin karaf --force` as you'll likely get an error
            about pushing to your fork's karaf branch.</div>
          <div><br>
          </div>
          <div>Having said that, it's probably going to take you a bit
            to go through it. `gitk` may or may not be helpful.
            Committing early and often (as well as rebasing against the
            latest master branch) would prevent this problem for you in
            the future. Hope that helps! If not, Marc may be your guy.</div>
          <div><br>
          </div>
          <div>Rachel</div>
          <div><br>
          </div>
        </div>
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On Wed, Mar 16, 2016 at 4:52 AM,
            Charles Moulliard <span dir="ltr">&lt;<a
                moz-do-not-send="true"
                href="mailto:cmoulliard@redhat.com" target="_blank"><a class="moz-txt-link-abbreviated" href="mailto:cmoulliard@redhat.com">cmoulliard@redhat.com</a></a>&gt;</span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">No
              advices from @Rachel or @Marc ?<br>
              <div class="">
                <div class="h5"><br>
                  <br>
                  On 08/03/16 14:30, Charles Moulliard wrote:<br>
                  &gt; Perhaps the option "git rebase --interactive" is
                  better ?<br>
                  &gt;<br>
                  &gt; I'm also thinking that the rebase should be done
                  from the commits of<br>
                  &gt; karaf branch to master. If this is the case, then
                  the cmds to be used are<br>
                  &gt;<br>
                  &gt; git checkout master<br>
                  &gt; git rebase --interactive karaf // squash of the
                  commits can be done<br>
                  &gt; within the editor<br>
                  &gt;<br>
                  &gt;<br>
                  &gt; On 08/03/16 12:44, Eric Wittmann wrote:<br>
                  &gt;&gt; @Marc or @Rachel - any advice to charles on
                  the best way to merge and<br>
                  &gt;&gt; squash?<br>
                  &gt;&gt;<br>
                  &gt;&gt; -Eric<br>
                  &gt;&gt;<br>
                  &gt;&gt; On 3/8/2016 3:21 AM, Charles Moulliard wrote:<br>
                  &gt;&gt;&gt; On 01/03/16 13:36, Eric Wittmann wrote:<br>
                  &gt;&gt;&gt;&gt; Hi Charles.  Here are some things we
                  would need before we can merge<br>
                  &gt;&gt;&gt;&gt; the karaf branch:<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; 1) rebase the karaf branch to master<br>
                  &gt;&gt;&gt;&gt; 2) squash the commits to a single
                  commit<br>
                  &gt;&gt;&gt;<br>
                  &gt;&gt;&gt;  &gt;&gt; Can you confirm my scenario to
                  rebase and squash ?<br>
                  &gt;&gt;&gt; git checkout karaf<br>
                  &gt;&gt;&gt; git rebase master<br>
                  &gt;&gt;&gt; --&gt; Fix merge issues and commit them ?<br>
                  &gt;&gt;&gt; git checkout master<br>
                  &gt;&gt;&gt; git merge --squash<br>
                  &gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; 3) thorough code review<br>
                  &gt;&gt;&gt;&gt; 4) testing<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; #1 - I think this is pretty
                  straightforward.<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; #2 - Normally I wouldn't mind a small
                  number of commits for a<br>
                  &gt;&gt;&gt;&gt; contribution like the karaf support,
                  but you've got 221 commits in the<br>
                  &gt;&gt;&gt;&gt; karaf branch, representing 117 files
                  changed or added. That's a very<br>
                  &gt;&gt;&gt;&gt; large impact on the project's commit
                  history and will make future<br>
                  &gt;&gt;&gt;&gt; diffs more difficult than is
                  warranted.  So that's the reason to<br>
                  &gt;&gt;&gt;&gt; squash the commits down to one (or at
                  most a handful).<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; #3 - I'll need to run through the
                  code with the rest of the apiman dev<br>
                  &gt;&gt;&gt;&gt; team so we're all familiar with the
                  changes.  We need some extra<br>
                  &gt;&gt;&gt;&gt; eyeballs on the code to make sure we
                  don't (for example) duplicate a<br>
                  &gt;&gt;&gt;&gt; lot of functionality.<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; #4 - Obviously we'll need to do some
                  testing to make sure everything<br>
                  &gt;&gt;&gt;&gt; is working as expected.<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; Unfortunately we've got a bunch of
                  high priority tasks at the moment,<br>
                  &gt;&gt;&gt;&gt; so it may be a little while before we
                  can get to #3 and #4. I'm happy<br>
                  &gt;&gt;&gt;&gt; to accomplish #1 and #2 at some point
                  in the future, although if you'd<br>
                  &gt;&gt;&gt;&gt; like to give it a try that would be
                  fine too.<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; -Eric<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt; On 3/1/2016 4:13 AM, Charles
                  Moulliard wrote:<br>
                  &gt;&gt;&gt;&gt;&gt; Hi,<br>
                  &gt;&gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt;&gt; Can we consider to merge Karaf
                  branch with Master - trunk ? What<br>
                  &gt;&gt;&gt;&gt;&gt; are the<br>
                  &gt;&gt;&gt;&gt;&gt; steps that we have to take care
                  in order to prepare the merge ?<br>
                  &gt;&gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt;&gt; Regards,<br>
                  &gt;&gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;&gt;&gt; Charles<br>
                  &gt;&gt;&gt;&gt;&gt;
                  _______________________________________________<br>
                  &gt;&gt;&gt;&gt;&gt; Apiman-dev mailing list<br>
                  &gt;&gt;&gt;&gt;&gt; <a moz-do-not-send="true"
                    href="mailto:Apiman-dev@lists.jboss.org">Apiman-dev@lists.jboss.org</a><br>
                  &gt;&gt;&gt;&gt;&gt; <a moz-do-not-send="true"
                    href="https://lists.jboss.org/mailman/listinfo/apiman-dev"
                    rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/apiman-dev</a><br>
                  &gt;&gt;&gt;&gt;&gt;<br>
                  &gt;&gt;&gt;<br>
                  &gt;<br>
                  <br>
                  _______________________________________________<br>
                  Apiman-dev mailing list<br>
                  <a moz-do-not-send="true"
                    href="mailto:Apiman-dev@lists.jboss.org">Apiman-dev@lists.jboss.org</a><br>
                  <a moz-do-not-send="true"
                    href="https://lists.jboss.org/mailman/listinfo/apiman-dev"
                    rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/apiman-dev</a><br>
                </div>
              </div>
            </blockquote>
          </div>
          <br>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>