chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
dasd_id: add s390 disk-label prober
[elogind.git]
/
test
/
test.block
diff --git
a/test/test.block
b/test/test.block
old mode 100644
(file)
new mode 100755
(executable)
index
622a660
..
294c47c
--- a/
test/test.block
+++ b/
test/test.block
@@
-11,19
+11,18
@@
if [ $# = "0" ] ; then
fi
SYSFSDIR=/sys # change this for a nonstand sysfs mount point
fi
SYSFSDIR=/sys # change this for a nonstand sysfs mount point
-BIN=.
/udev
# location of your udev binary
+BIN=.
./udev
# location of your udev binary
export ACTION=$1 # 'add' or 'remove'
for i in ${SYSFSDIR}/block/*; do
# add each drive
export ACTION=$1 # 'add' or 'remove'
for i in ${SYSFSDIR}/block/*; do
# add each drive
- export DEVPATH=
"/"`echo $i | cut --delimiter='/' --fields=3-`
+ export DEVPATH=
${i#${SYSFSDIR}}
$BIN block
# add each partition, on each device
for j in $i/*; do
if [ -f $j/dev ]; then
$BIN block
# add each partition, on each device
for j in $i/*; do
if [ -f $j/dev ]; then
- export DEVPATH="/"`echo $j | \
- cut --delimiter='/' --fields=3-`
+ export DEVPATH=${j#${SYSFSDIR}}
$BIN block
fi
done
$BIN block
fi
done