#!/bin/sh # perl-bump experimental tool # Robin H. Johnson # v0.1 - 2008/07 # v0.2 - 2008/11 # v0.3 - 2008/12 # v0.5 - 2009/02/23 # # This isn't a perfect tool, but it does make it possible to quickly handle # most dev-perl bumps with ease. # # TODO: # - enable ALL/MOST USE flags to test # - Sandbox in the package deps needed to build or test # - Support more VCS options # - error checking on input more pn="$1" ov="$2" nv="$3" o="${pn}-${ov}.ebuild" n="${pn}-${nv}.ebuild" pushd $pn >/dev/null cvs up [ -f "$n" ] || cp $o $n ekeyword ~all $n M="Version bump via perl-bump experimental tool." USE=test FEATURES=test ebuild $n digest clean package rc=$? if [ $rc -ne 0 ]; then echo "Failed to test (rc=$rc)" 1>&2 exit 1 fi egrep "^/${n}/0/dummy timestamp" CVS/Entries -sq || cvs add $n rc=$? if [ $rc -ne 0 ]; then echo "Failed to add to CVS (rc=$rc)" 1>&2 exit 1 fi egrep "\+${n}[,;:\n ]" ChangeLog -sq && echo "Already in ChangeLog" || echangelog "${M}" ebuild $n digest repoman commit -m "${M}" popd >/dev/null