mirror of https://schlomp.space/tastytea/hashboot
tidying up a bit :-)
parent
ae9b123d5e
commit
629f57f61b
27
hashboot
27
hashboot
|
@ -121,22 +121,21 @@ then
|
||||||
#Compare $DIGEST_FILE_TMP against ${DIGEST_FILE} and exit, when fine. Otherwise do magic.
|
#Compare $DIGEST_FILE_TMP against ${DIGEST_FILE} and exit, when fine. Otherwise do magic.
|
||||||
if diff -q --ignore-matching-lines='^#' ${DIGEST_FILE} ${DIGEST_FILE_TMP} ;
|
if diff -q --ignore-matching-lines='^#' ${DIGEST_FILE} ${DIGEST_FILE_TMP} ;
|
||||||
then
|
then
|
||||||
echo "alles fine und die exit definieren"
|
|
||||||
die 0
|
die 0
|
||||||
else
|
else
|
||||||
#Compare actual hashes of MBR against saved hashes.
|
# #Compare actual hashes of MBR against saved hashes.
|
||||||
if [ "$(grep ${MBR_TMP} ${DIGEST_FILE})" != "$(grep ${MBR_TMP} ${DIGEST_FILE_TMP})" ]
|
# if [ "$(grep ${MBR_TMP} ${DIGEST_FILE})" != "$(grep ${MBR_TMP} ${DIGEST_FILE_TMP})" ]
|
||||||
then
|
# then
|
||||||
echo "at least mbr must be written."
|
# echo "at least mbr must be written."
|
||||||
fi
|
# fi
|
||||||
#Compare actual hashes of /boot against saved hashes.
|
# #Compare actual hashes of /boot against saved hashes.
|
||||||
if [ "$(grep -v ${MBR_TMP} ${DIGEST_FILE})" != "$(grep -v ${MBR_TMP} ${DIGEST_FILE_TMP})" ]
|
# if [ "$(grep -v ${MBR_TMP} ${DIGEST_FILE})" != "$(grep -v ${MBR_TMP} ${DIGEST_FILE_TMP})" ]
|
||||||
then
|
# then
|
||||||
echo "anything here, must be rewritten."
|
# echo "anything here, must be rewritten."
|
||||||
#if interactive ask if rewrite einzeln?
|
# #if interactive ask if rewrite einzeln?
|
||||||
echo "find out which one?"
|
# echo "find out which one?"
|
||||||
#read z und so weiter..
|
# #read z und so weiter..
|
||||||
fi
|
# fi
|
||||||
mv ${DIGEST_FILE_TMP} ${DIGEST_FILE} || die 7
|
mv ${DIGEST_FILE_TMP} ${DIGEST_FILE} || die 7
|
||||||
echo "List of hashes written to ${DIGEST_FILE}"
|
echo "List of hashes written to ${DIGEST_FILE}"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue