Files
image-workbench-desktop/scripts/diag-tail.sh
T
qiqi 30cf375ea0
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 41s
docs+tooling: 工程流程优化约定(preflight 体检 / diag-tail 日志过滤)
2026-12-02 06:54:16 +08:00

10 lines
388 B
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env bash
# 取资料目录 _boot.log 的关键行。
set -uo pipefail
DIR="${IWB_DATA_DIR:-$HOME/Documents/ImageWorkbench}"
LOG="$DIR/_boot.log"
if [ ! -f "$LOG" ]; then echo "找不到 $LOG(可用 IWB_DATA_DIR 指定资料目录)"; exit 2; fi
PAT="${*:-plugin-img|perf |thumb-fail|mem }"
echo "== $LOG (匹配:$PAT)"
tail -n 400 "$LOG" | grep -E "$PAT" | tail -n 40