commit 378286b

hovercats  ·  2024-07-29 16:42:18 +0000 UTC
parent a1ff506
bmks: exit if no selection is made
1 files changed,  +2, -0
+2, -0
 1@@ -23,6 +23,7 @@ fn add {
 2 
 3 fn del {
 4 	selection=`{cat $bookmarks | dmenu -l 10 -c -p 'Delete: '} 
 5+	test ! -z $selection || exit 1
 6 	grep -v $"selection $bookmarks > _
 7 	mv -f _ $bookmarks
 8 }
 9@@ -33,6 +34,7 @@ fn list {
10 
11 fn go_to {
12 	selection=`{cat $bookmarks | dmenu -c -i -l 10 | awk '{print $NF}'}
13+	test ! -z $selection || exit 1
14 	exec $BROWSER $selection
15 }
16