From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57659) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UkztO-0005xK-Cv for qemu-devel@nongnu.org; Fri, 07 Jun 2013 12:52:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UkztM-0004M4-6m for qemu-devel@nongnu.org; Fri, 07 Jun 2013 12:51:58 -0400 Received: from e31.co.us.ibm.com ([32.97.110.149]:42852) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UkztL-0004LL-U3 for qemu-devel@nongnu.org; Fri, 07 Jun 2013 12:51:56 -0400 Received: from /spool/local by e31.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 7 Jun 2013 10:51:54 -0600 Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com [9.17.195.107]) by d03dlp01.boulder.ibm.com (Postfix) with ESMTP id 69B7F1FF001F for ; Fri, 7 Jun 2013 10:46:40 -0600 (MDT) Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r57Gpfgb142536 for ; Fri, 7 Jun 2013 10:51:41 -0600 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r57GplXQ025449 for ; Fri, 7 Jun 2013 10:51:47 -0600 From: Anthony Liguori In-Reply-To: <51B1FED9.2050000@redhat.com> References: <51B04F31.4040908@redhat.com> <20130607144400.GC409@localhost.localdomain> <51B1FED9.2050000@redhat.com> Date: Fri, 07 Jun 2013 11:51:36 -0500 Message-ID: <87y5al27af.fsf@codemonkey.ws> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: [Qemu-devel] [PATCH] script: git script to compile every commit in a range of commits List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Laszlo Ersek , Jeff Cody Cc: kwolf@redhat.com, blauwirbel@gmail.com, alex.williamson@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com Laszlo Ersek writes: > On 06/07/13 16:44, Jeff Cody wrote: > >> Thanks. I can either do the above changes for a v2, or as follow on >> patches. > > Whichever is easier for you, certainly! I'm fine with the script > going-in as is. A suggestion I'll make is to split the script into two parts. git-bisect run is a terribly useful command and I use a bisect script that looks like this: #!/bin/sh set -e pushd ~/build/qemu make -j1 || exit 1 popd # Add right seed here if test "$1"; then "$@" fi I'm sure we all have bisect scripts like this. What you're proposing is very similar to bisect but instead of doing a binary search, it does a linear search starting from the oldest commit. Basically: #!/bin/sh refspec="$1" shift git rev-list $refspec | while read commit; do git checkout $commit "$@" || exit $? done And indeed, I have a local script called git-foreach to do exactly this. I suspect a nicer version would make a very good addition to the git project. So to bisect for a make check failure, I do: git bisect run bisect.sh make check Or to bisect for a qemu-test failure: git bisect run bisect.sh qemu-test-regress.sh With git-foreach, you can do: git-foreach bisect.sh To do a simple build test. Or you can do: git-foreach git show checkpatch-head.sh etc. Regards, Anthony Liguori > > Cheers, > Laszlo