Little fix to be able to use portimport(1) even with a non standard $PORTSDIR, I do not like this patch that much, maybe there could be a better way to achieve the same result. Cheers Giovanni
Index: portimport =================================================================== RCS file: /cvs/ports/infrastructure/bin/portimport,v retrieving revision 1.2 diff -u -p -u -p -r1.2 portimport --- portimport 11 Apr 2013 15:18:00 -0000 1.2 +++ portimport 12 Apr 2013 14:21:58 -0000 @@ -38,6 +38,9 @@ done cvsroot=$u...@cvs.openbsd.org:/cvs error=false fulldir=$(pwd) +cd ../../ +portsdir=$(pwd) +cd - importname="ports/${fulldir##*/ports/*(mystuff/|openbsd-wip/|p5-ports-wip/)}" timestamp=$(date '+%Y%m%d') @@ -61,9 +64,9 @@ cvs -n -d$cvsroot import $importname $us read ans?'Correct path? [y/n] ' if [[ $ans == +(y|Y) ]]; then cvs -d$cvsroot import $importname $user ${user}_$timestamp - cd /usr/$importname/../ + cd $portsdir/$importname/../ cvs -d$cvsroot update -AdP ${fulldir##*/} echo "Don't forget to commit the category Makefile when you're done!" - cd /usr/$importname/../ + cd $portsdir/$importname/../ pwd fi