From 1af6a0ab3d3ea57763e0eaab4fa30d33b4e95d0f Mon Sep 17 00:00:00 2001 From: snailed Date: Fri, 21 Oct 2022 19:25:14 +0000 Subject: [PATCH] fix regex --- .local/share/trash-restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/share/trash-restore b/.local/share/trash-restore index 0b2db442..3663d107 100644 --- a/.local/share/trash-restore +++ b/.local/share/trash-restore @@ -9,7 +9,7 @@ list() { for file in "$1"/*; do [ "$(head -1 "$file")" = "[Trash Info]" ] && \ fpath=$(grep Path "$file" | cut -d '=' -f2) && \ - echo "$fpath" | grep -qP "^$2" && \ + echo "$fpath" | grep -qP "^$2/[^/]+$" && \ printf "%s %s %s\n" \ "$(basename "$file")" \ "$fpath" \