Skip to content

Commit

Permalink
Merge pull request #20 from amiaopensource/retokromer-patch-1
Browse files Browse the repository at this point in the history
housekeeping
  • Loading branch information
dericed authored Sep 21, 2016
2 parents ee35be3 + 32425ef commit 41d120a
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions verifylto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# name: verifylto
# description: verifylto creates a text document with a list of checksums that are generated after a readback. This is to ensure that all files transferred over correctly.
HIDDEN_FILES=""
Expand Down Expand Up @@ -30,21 +30,18 @@ while getopts ":t:e" opt ; do
done
shift $(( ${OPTIND} - 1 ))


SOURCE_DIR="${1}"
if [[ ! $(echo "${TAPE_SERIAL}" | grep "${TAPE_SERIAL_REGEX}") ]] ; then
echo "${TAPE_SERIAL} is not valid. The tape id must be exactly 6 capital letters and/or numbers."
_usage
exit 1
fi

TAPE_PATH="${TAPE_MOUNT_POINT}/${TAPE_SERIAL}"

_checkdir "${TAPE_PATH}"

VERIFYTIME=$(_get_iso8601_c)
READBACKDIR="${LTO_LOGS}/readback_checksums"
_mkdir2 "${READBACKDIR}"
_mkdir2 "${READBACKDIR}"
find "${TAPE_PATH}" -type f ! -name .DS_Store -exec md5deep -rel "{}" >> "${READBACKDIR}/${TAPE_SERIAL}_ReadBack_checksum_${VERIFYTIME}.md5" \;

case "${TAPE_EJECT}" in
Expand Down

0 comments on commit 41d120a

Please sign in to comment.