tests/env-ddf-template: add helper function for checksums

Signed-off-by: Martin Wilck <mwilck@arcor.de>
Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
mwilck@arcor.de 2013-09-25 22:42:00 +02:00 committed by NeilBrown
parent d5b8e34061
commit e00d9c10c1
1 changed files with 4 additions and 0 deletions

View File

@ -1,3 +1,7 @@
sha1_sum() {
sha1sum "$1" | cut -c 1-40
}
get_rootdev() {
local dev=$(stat -c %D /)
local maj=$(expr $dev : '\(..\)')