- Fix 'beadm mount'

Submitted by:	Adrian Waters <awaters@draenan.net>
This commit is contained in:
Bryan Drewery 2013-10-27 14:04:17 +00:00
parent e7fd2d6dfa
commit 14bd59301f
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=331772
2 changed files with 20 additions and 0 deletions

View file

@ -2,6 +2,7 @@
PORTNAME= beadm
PORTVERSION= 1.0
PORTREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= GH \
http://mirror.shatow.net/freebsd/${PORTNAME}/ \

View file

@ -0,0 +1,19 @@
--- ./beadm.orig 2013-10-27 09:02:48.041131265 -0500
+++ ./beadm 2013-10-27 09:03:20.579130647 -0500
@@ -715,7 +715,6 @@
echo "ERROR: Cannot mount '${2}' at '${TARGET}' mountpoint"
exit 1
fi
- PREFIX=$( echo ${POOL}/${BEDS}/${2}/ | sed 's/\//\\/g' )
zfs list -H -o name,mountpoint -r ${POOL}/${BEDS}/${2} \
| grep -v -E "[[:space:]](legacy|none)$" \
| sort -n \
@@ -732,7 +731,7 @@
continue
;;
(*)
- MOUNTPOINT="/$( echo "${FS}" | sed s/"${PREFIX}"//g )"
+ MOUNTPOINT="/$( echo "${FS}" | sed s^"${POOL}/${BEDS}/${2}/"^^g )"
;;
esac
fi