mirror of
https://github.com/tw93/Mole.git
synced 2026-03-22 20:15:07 +00:00
fix(purge): remove 60-char hard cap on path display width (issue #564)
The path column in 'mo purge' selection was capped at 60 characters regardless of terminal width. On wide terminals (120+ cols) this caused long project paths like ~/GitHub/Ulama/transformer-project to be truncated unnecessarily to ~17 visible characters. Remove the hard 60-char cap and let the available terminal space be the only upper bound, which is already computed as: available_for_path = terminal_width - fixed_overhead Paths now use as much space as the terminal allows while still keeping the size and artifact-type columns readable. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -1175,7 +1175,6 @@ clean_project_artifacts() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
[[ $available_width -lt $min_width ]] && available_width=$min_width
|
[[ $available_width -lt $min_width ]] && available_width=$min_width
|
||||||
[[ $available_width -gt 60 ]] && available_width=60
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Truncate project path if needed
|
# Truncate project path if needed
|
||||||
@@ -1273,7 +1272,6 @@ clean_project_artifacts() {
|
|||||||
|
|
||||||
[[ $max_path_display_width -lt $min_path_width ]] && max_path_display_width=$min_path_width
|
[[ $max_path_display_width -lt $min_path_width ]] && max_path_display_width=$min_path_width
|
||||||
[[ $available_for_path -lt $max_path_display_width ]] && max_path_display_width=$available_for_path
|
[[ $available_for_path -lt $max_path_display_width ]] && max_path_display_width=$available_for_path
|
||||||
[[ $max_path_display_width -gt 60 ]] && max_path_display_width=60
|
|
||||||
# Ensure path width is at least 5 on very narrow terminals
|
# Ensure path width is at least 5 on very narrow terminals
|
||||||
[[ $max_path_display_width -lt 5 ]] && max_path_display_width=5
|
[[ $max_path_display_width -lt 5 ]] && max_path_display_width=5
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user