From 737cf3c79a03489a53b250cf53cf2a8f53f603a4 Mon Sep 17 00:00:00 2001 From: Harald Pfeiffer Date: Mon, 25 Nov 2019 10:04:43 +0100 Subject: +documentation scripts --- documentation/aux/block-inventory | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100755 documentation/aux/block-inventory (limited to 'documentation/aux/block-inventory') diff --git a/documentation/aux/block-inventory b/documentation/aux/block-inventory new file mode 100755 index 0000000..c8dc3f3 --- /dev/null +++ b/documentation/aux/block-inventory @@ -0,0 +1,10 @@ +#!/bin/bash + +SCDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +source "$SCDIR/ctrl-c"||exit 1 +ODETFIL="$SCDIR/../blockdevices" + +echo -n "Fetching blocks..." +true>"$ODETFIL";[ "$?" -ne 0 ]&&echo "failed."&&exit 1||echo -n "." +echo -n ".";lsblk -im -o+FSTYPE,MIN-IO,MOUNTPOINT 2>/dev/null|sed 's/luks-[^\ ]\+/luks- /g' >"$ODETFIL" +[ "$?" -ne 0 ]&&echo ".failed."||echo ".done." -- cgit v1.2.3