Package: subversion-tools Version: 1.5.6dfsg-1 Severity: wishlist Tags: patch
Hi! Today I found myself in need of "svn-bisect run <cmd>" functionality, so I implemented it. It mimics the semantics of its git equivalent. -- System Information: Debian Release: squeeze/sid APT prefers unstable APT policy: (500, 'unstable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.26-libre2-2-amd64 (SMP w/2 CPU cores) Locale: LANG=ca_AD.UTF-8, LC_CTYPE=ca_AD.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Versions of packages subversion-tools depends on: ii subversion 1.5.6dfsg-1 Advanced version control system Versions of packages subversion-tools recommends: pn exim4 | mail-transport-agent <none> (no description available) pn libconfig-inifiles-perl <none> (no description available) ii libsvn-perl 1.5.6dfsg-1 Perl bindings for Subversion ii liburi-perl 1.37+dfsg-1 Manipulates and accesses URI strin pn python-subversion <none> (no description available) ii rsync 3.0.5-1 fast remote file copy program (lik ii xsltproc 1.1.24-2 XSLT command line processor Versions of packages subversion-tools suggests: pn libsvn-ruby1.8 <none> (no description available) -- no debconf information
--- /srv/chroot/sid/usr/bin/svn-bisect 2009-02-26 04:53:52.000000000 +0100 +++ bin/svn-bisect 2009-07-01 00:49:41.000000000 +0200 @@ -1,6 +1,6 @@ #!/bin/sh -e # -# Copyright (C) 2008 Robert Millan +# Copyright (C) 2008,2009 Robert Millan # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -28,6 +28,7 @@ $0 start $0 good [revision] $0 bad [revision] + $0 run [cmd] EOF } @@ -45,6 +46,24 @@ echo $1 > .svn-bisect/$what fi ;; + run) + shift + cmd=$1 + + if ! test -e .svn-bisect ; then + # This was the last run + exit 0 + fi + + (set +e ; ${cmd} ; case $? in + 125) $0 skip ;; + 0) $0 good ;; + *) $0 bad ;; + esac) + + # Recurse + exec $0 run ${cmd} + ;; -h|--help) usage exit 0 @@ -72,6 +91,7 @@ echo "Regression found!" echo "Last good revision: $good" echo "First bad revision: $bad" + rm -rf .svn-bisect exit 0 fi