From b8b2e403ae64b417a5928cb6a96b00478869b4f3 Mon Sep 17 00:00:00 2001 From: ranke Date: Mon, 14 Dec 2015 05:31:40 +0000 Subject: Fix and improvements - Copy sources to $DIST directory so quilt using packages work (littler, r-cran-coda, r-cran-rjags...) - Do not use getopts as the approach used did not work with multiple options - Use -s/--skip instead of -n to skip updates - Use -k/--keep to keep sources under $DIST directory git-svn-id: svn+ssh://stiller/home/schatz/reps/r-backports@112 f247ebf9-aa24-0410-a698-f940e971ad2b --- backport_others | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'backport_others') diff --git a/backport_others b/backport_others index 697ede1..5e5ab1c 100644 --- a/backport_others +++ b/backport_others @@ -9,14 +9,14 @@ usage() { echo "Usage: ./backport_others [options] squeeze|wheezy|jessie" echo "Options:" -echo " -n Skip apt-get update/upgrade and pbuilder update" +echo " -s Skip apt-get update/upgrade and pbuilder update" } -update=true -while getopts ":n" flag; do +skip=false +while getopts ":s" flag; do case $flag in - n) - update=false + s) + skip=true ;; \?) echo "Invalid option: -$OPTARG" >&2 @@ -30,7 +30,7 @@ if [ $# -lt 1 ]; then usage; exit 1; fi DIST=$1 # Update pbuilder chroot -if [ "$update" = true ] +if [ "$skip" = true ] then sudo -E pbuilder update fi @@ -45,6 +45,6 @@ export DIST # Packages to backport to squeeze/wheezy/jessie (without rpy2): for i in lattice nlme rmatrix mgcv boot cluster codetools foreign kernsmooth r-cran-class r-cran-coda r-cran-spatial r-cran-nnet r-cran-mass rodbc rpart survival r-cran-littler rpy rkward r-cran-rjags; do - ./backport -n $i $DIST + ./backport -s $i $DIST done -- cgit v1.2.1