1
0
mirror of https://github.com/tw93/Mole.git synced 2026-03-23 15:20:06 +00:00

chore: auto format code

This commit is contained in:
tw93
2026-02-28 11:03:16 +08:00
parent 1be71edc9d
commit 7d70889ad4
21 changed files with 145 additions and 128 deletions

View File

@@ -58,7 +58,7 @@ hint_get_path_size_kb_with_timeout() {
record_project_artifact_hint() {
local path="$1"
((PROJECT_ARTIFACT_HINT_COUNT++))
((PROJECT_ARTIFACT_HINT_COUNT++)) || true
if [[ ${#PROJECT_ARTIFACT_HINT_EXAMPLES[@]} -lt 2 ]]; then
PROJECT_ARTIFACT_HINT_EXAMPLES+=("${path/#$HOME/~}")
@@ -74,8 +74,8 @@ record_project_artifact_hint() {
local size_kb=""
if size_kb=$(hint_get_path_size_kb_with_timeout "$path" "$timeout_seconds"); then
if [[ "$size_kb" =~ ^[0-9]+$ ]]; then
((PROJECT_ARTIFACT_HINT_ESTIMATED_KB += size_kb))
((PROJECT_ARTIFACT_HINT_ESTIMATE_SAMPLES++))
((PROJECT_ARTIFACT_HINT_ESTIMATED_KB += size_kb)) || true
((PROJECT_ARTIFACT_HINT_ESTIMATE_SAMPLES++)) || true
else
PROJECT_ARTIFACT_HINT_ESTIMATE_PARTIAL=true
fi
@@ -140,8 +140,8 @@ probe_project_artifact_hints() {
local root_projects_scanned=0
if is_quick_purge_project_root "$root"; then
((scanned_projects++))
((root_projects_scanned++))
((scanned_projects++)) || true
((root_projects_scanned++)) || true
if [[ $scanned_projects -gt $max_projects ]]; then
PROJECT_ARTIFACT_HINT_TRUNCATED=true
stop_scan=true
@@ -175,8 +175,8 @@ probe_project_artifact_hints() {
break
fi
((scanned_projects++))
((root_projects_scanned++))
((scanned_projects++)) || true
((root_projects_scanned++)) || true
if [[ $scanned_projects -gt $max_projects ]]; then
PROJECT_ARTIFACT_HINT_TRUNCATED=true
stop_scan=true
@@ -206,7 +206,7 @@ probe_project_artifact_hints() {
;;
esac
((nested_count++))
((nested_count++)) || true
if [[ $nested_count -gt $max_nested_per_project ]]; then
break
fi