mirror of
https://github.com/samuelncui/yatm.git
synced 2026-11-08 04:18:03 +00:00
Unify file queries and Scan execution, retain indexed Identical results, improve Job and Preview workflows, and verify release packaging.
20 lines
347 B
Bash
Executable File
20 lines
347 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -ex;
|
|
|
|
mkdir -p "${TAPE_DIR}"
|
|
exec > >(tee -a "${TAPE_DIR}/ltfs.log") 2>&1
|
|
|
|
mt -f "${DEVICE}" load
|
|
sleep 5
|
|
|
|
for i in {1..60}; do
|
|
if stenc -f "${DEVICE}" -e on -k "${KEY_FILE}" -kd "${TAPE_BARCODE}" -a 1 --ckod; then
|
|
sleep 3
|
|
exit 0
|
|
fi
|
|
if (( i == 60 )); then
|
|
exit 1
|
|
fi
|
|
sleep 5
|
|
done
|