mirror of
https://github.com/Llewellynvdm/Tomb.git
synced 2024-12-30 12:50:39 +00:00
square parens detection in list_mounted_tombs
This commit is contained in:
parent
6182a56fb6
commit
21347f3657
10
tomb
10
tomb
@ -2272,10 +2272,13 @@ BEGIN { main="" }
|
||||
main=$1
|
||||
}
|
||||
'
|
||||
} || {
|
||||
# list a specific tomb
|
||||
} || { # list a specific tomb
|
||||
# add square parens if not present
|
||||
local tname
|
||||
if [[ "${1[1]}" = "[" ]]; then tname=$1
|
||||
else tname="[$1]"; fi
|
||||
mount -l \
|
||||
| awk -vtomb="[$1]" '
|
||||
| awk -vtomb="$tname" '
|
||||
BEGIN { main="" }
|
||||
/^\/dev\/mapper\/tomb/ {
|
||||
if($7!=tomb) next;
|
||||
@ -2609,7 +2612,6 @@ umount_tomb() {
|
||||
for t in ${mounted_tombs}; do
|
||||
mapper=`basename ${t[(ws:;:)1]}`
|
||||
|
||||
# strip square parens from tombname
|
||||
tombname=${t[(ws:;:)5]}
|
||||
tombmount=${t[(ws:;:)2]}
|
||||
tombfs=${t[(ws:;:)3]}
|
||||
|
Loading…
Reference in New Issue
Block a user