feat(tools): sha256-matcher, cheat script tweaks

This commit is contained in:
2023-07-12 22:44:08 +03:00
parent 22090129ec
commit 83eb7d861e
4 changed files with 97 additions and 4 deletions

View File

@@ -51,8 +51,10 @@ for d in "$TLDR_TEMP_DIR"/pages/*; do
TLDR_FILE="$SECTION_DIR/${FILENAME}"
# echo "-> dest: $TLDR_FILE"
if [ ! -f "$TLDR_FILE" ]; then
cp "$FILE" "$TLDR_FILE" && msg_run "$TLDR_FILE"
replacable "$FILE" "$TLDR_FILE"
override=$?
if [ "$override" -ne 1 ]; then
cp "$FILE" "$TLDR_FILE" && msg_run "Updated: $TLDR_FILE"
fi
if [ -f "$TLDR_FILE" ] && [ '---' != "$(head -1 < "$TLDR_FILE")" ]; then