Browse Source

Changed DIR variable

Matteo Zeccoli Marazzini 1 year ago
parent
commit
db3c3e4543
2 changed files with 2 additions and 1 deletions
  1. 1 0
      check-device.sh
  2. 1 1
      newdisk-automator

+ 1 - 0
check-device.sh

@@ -21,6 +21,7 @@ check_device()
 	fi
 
 	if pvs | grep --quiet "${DEVICE}" ; then
+		# check if the device has a open (e.g. mounted) lv
 		if [ $(lvs --noheadings --select vg_name="$(pvs --noheadings --select pv_name=~"${DEVICE}" -o vg_name)" --select lv_device_open!=0 | wc -l) -ne 0 ] ; then
 			fatal ${LVMUSED_E} "${DEVICE} is part of a used lvm volume"
 		fi

+ 1 - 1
newdisk-automator

@@ -1,6 +1,6 @@
 #!/bin/bash
 
-DIR="/home/matteozeccolimarazzini/newdisk-automator"
+DIR="."
 PROGRAM_NAME="$0"
 
 . "${DIR}/error.sh"