Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:59128 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 56744 invoked from network); 23 Mar 2012 00:09:36 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 23 Mar 2012 00:09:36 -0000 Authentication-Results: pb1.pair.com header.from=kiall@managedit.ie; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=kiall@managedit.ie; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain managedit.ie designates 209.85.210.170 as permitted sender) X-PHP-List-Original-Sender: kiall@managedit.ie X-Host-Fingerprint: 209.85.210.170 mail-iy0-f170.google.com Received: from [209.85.210.170] ([209.85.210.170:50590] helo=mail-iy0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id B1/0D-16309-E3FBB6F4 for ; Thu, 22 Mar 2012 19:09:35 -0500 Received: by iaeh11 with SMTP id h11so4358832iae.29 for ; Thu, 22 Mar 2012 17:09:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=managedit.ie; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=vn8i7nExSN+Pamc5y1cB0XkX9HqSz788Zf59zHWgwQI=; b=WeRnU2471Qz/KLOFHQK4gaj6uLhqwFeD3Mwoj3d9cg4GwRAB//0mCjTjWERNCSm6o6 rUruti98G1mxMVz7Q1ZQwStjuTLbHRfmEyduubofRKbsJsyxj2+j5ab7vK7+gNVJm5El 9t3mUT0oDsPzavlpmG5SeZvywuPEEqwykxLIU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:x-gm-message-state; bh=vn8i7nExSN+Pamc5y1cB0XkX9HqSz788Zf59zHWgwQI=; b=U9pM3kkZVCRx43kxm2OZ1Jvahl7SxDy+nkHeEEs1YPTRPW24UJ7T7onJPXR6zAZY+4 8vlVfThhprAFFV9z5aDai83jMFHrISA+9GD5ffl3H4LzAPv6o2Gv6BfsjGeLwipWkNnv cR/qbUbPrLkj1hFPGLJoJ43bgEP1RYy+ok/1Egfzc5UblXMpTiYwiowmR99OJ96sQw/o FyaXGh6qffOftKpYJddAR0uTGOr1m550Po99QSU/g7RFyHcvwsPCPUtGEHyTz8auBSkt AtvT5/AF7ggIWVMar0/noczhg3SJjM+MTPUqvTjrXHhSjUOdIjY9Qvxpb1cIM5v2QJRJ sRIw== Received: by 10.50.159.198 with SMTP id xe6mr566289igb.74.1332461372569; Thu, 22 Mar 2012 17:09:32 -0700 (PDT) MIME-Version: 1.0 Received: by 10.231.209.193 with HTTP; Thu, 22 Mar 2012 17:09:12 -0700 (PDT) In-Reply-To: <4F6BB4AA.2090208@oracle.com> References: <4F6BB4AA.2090208@oracle.com> Date: Fri, 23 Mar 2012 00:09:12 +0000 Message-ID: To: Christopher Jones Cc: PHP Developers Mailing List Content-Type: multipart/alternative; boundary=14dae93405a5c9f7d904bbddd6ac X-Gm-Message-State: ALoCoQnbMKxsBJa1OoTmM2J3HHamxVFpS3cUMpaF7MhXFygSG3l3ou2XWYTiWXu/boiY2ZwLY2u1 Subject: Re: [PHP-DEV] Git merging fun and a local clone-per branch workflow From: kiall@managedit.ie (Kiall Mac Innes) --14dae93405a5c9f7d904bbddd6ac Content-Type: text/plain; charset=ISO-8859-1 On Thu, Mar 22, 2012 at 11:24 PM, Christopher Jones < christopher.jones@oracle.com> wrote: > 1. I had fun with a couple of small git merges today. I was trying to > use local clones as briefly outlined on irc by dsp. Multiple clones for each branch will be *much **much* harder to manage from a Git POV. From a build POV though, it might be easier as you can avoid lots of `make clean` etc.. > The goal is to > have different local directories for each of the three branches: > 5.3, 5.4 and 'trunk'. The resulting pushes I made today are a > little strange and need reviewing/reverting. For example my > oci8/README fix doesn't seem to have got merged to 5.3. With multiple local clones, you can end up with some strange situations if you don't know exactly what you're pushing/pulling between them AND the central repo.. > At some stage somehow '21 commits' got merged to PHP 5.4. I swear 'git > diff' was only showing my changes. > Right - `git diff` shows the different between HEAD (The last commit of the branch your are currently on) and what you have yet to commit. So - When you then merge $current_branch into $other_branch, the merge will merge all commits from $current_branch into $other_branch, not just your own.. eg: $ git checkout PHP-5.3 # Edit some files $ git commit .. # Edit some files 2 $ git commit .. $ git checkout PHP-5.4 $ git merge PHP-5.3 2 commits will be merged - Assuming nobody else has changed 5.3 since the last time anyone merged it into 5.4 If on the other hand, someone else committed to 5.3, did not merge to 5.4, and you have that commit in your 5.3 branch.. then the merge will do 3 commits, even though you only made 2. This is likely what you saw. `git log --oneline --graph` is a useful command to try and understand what happened, and what was merged where.. Thanks, Kiall --14dae93405a5c9f7d904bbddd6ac--