summary refs log tree commit diff
path: root/bin/mnts
diff options
context:
space:
mode:
authorRobert Günzler <r@gnzler.io>2021-09-25 14:58:22 +0200
committerRobert Günzler <r@gnzler.io>2021-09-25 14:58:22 +0200
commit3768a6c1488c148cc07481687a47cb7cce02ad35 (patch)
tree633a7219902e561b3e05e46974d357171a99fa03 /bin/mnts
parent18388e3cd72480510a25d4fb0ab9bb45d6c28baf (diff)
bin/mnts: lsblk now returns list of mountpoints
Diffstat (limited to 'bin/mnts')
-rwxr-xr-xbin/mnts10
1 files changed, 5 insertions, 5 deletions
diff --git a/bin/mnts b/bin/mnts
index 56eb185..cbf534c 100755
--- a/bin/mnts
+++ b/bin/mnts
@@ -48,8 +48,8 @@ handle() {
 	done
 }
 
-lsblk -fJ \
-	| jq -r '.. | select(.uuid?!="" and .name?) | select((.name | test("hibiki|nvme") | not) and .fstype?) | [ .name, .label, .mountpoint // "" ] | @tsv' \
-	| awk -F'\t' '{printf "/dev/%-10s\t%-15s\t%s\n", $1, $2, $3;}' \
-	| menu --list=8 \
-	| handle
+lsblk -fJ |
+	jq -r '.. | select(.uuid?!="" and .name?) | select((.name | test("hibiki|nvme") | not) and .fstype?) | [ .name, .label, .mountpoints[0] // "" ] | @tsv' |
+	awk -F'\t' '{printf "/dev/%-10s\t%-15s\t%s\n", $1, $2, $3;}' |
+	menu --list=8 |
+	handle