1
0
Fork 0
mirror of https://github.com/Luzifer/archrepo.git synced 2024-11-12 19:32:43 +00:00
archrepo/scripts/has_archive_mix.sh
Knut Ahlers 3dfe38a9e5
Prepare migration to zstd archives
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2020-01-05 23:26:10 +01:00

16 lines
425 B
Bash

#!/bin/bash
set -euo pipefail
[[ $(find . -name '*.tar.zstd' | wc -l) -gt 0 ]] || {
echo "No ZStd archives found, nothing to worry"
exit 0
}
[[ $(find . -name '*.tar.xz' | wc -l) -gt 0 ]] && {
echo "Both XZ and ZStd archives found, pay attention!"
}
[[ $(find . -name '*.db.tar.xz' | wc -l) -gt 0 ]] && [[ $(find . -name '*.db.tar.zstd' | wc -l) -gt 0 ]] && {
echo "Found XZ and ZStd databases! Check this!"
exit 1
}