Fix review findings: dual-entry image capture, image blob GC at limit, stdin drain, fuzzy query edge cases, uri encoding, GC queue, temp-file pruning, theme border widths

This commit is contained in:
2026-09-05 15:43:33 +01:00
parent 44808ffd2c
commit 63a003e4a5
11 changed files with 73 additions and 41 deletions
+3 -1
View File
@@ -28,6 +28,8 @@ open_text() {
local dir file
dir="${XDG_STATE_HOME:-$HOME/.local/state}/omarchy/clipboard-open"
mkdir -p "$dir"
# Prune temp copies older than a week; nothing else reclaims them.
find "$dir" -type f -name 'clipboard.*.txt' -mtime +7 -delete 2>/dev/null || true
file=$(mktemp --tmpdir="$dir" clipboard.XXXXXX.txt)
printf '%s' "$text" >"$file"
exec omarchy-launch-editor "$file"
@@ -43,7 +45,7 @@ case $(jq -r '.type' <<<"$entry") in
exec xdg-open "$path"
;;
files)
first=$(jq -r '.paths[0]' <<<"$entry")
first=$(jq -r '.paths[0] // empty' <<<"$entry")
[[ -n $first ]] || exit 0
exec xdg-open "$first"
;;