feat(qutebrowser): fix buku userscript issues.

This commit is contained in:
CronyAkatsuki 2025-06-09 10:42:08 +02:00
parent f78a148870
commit 2294061f59

View file

@ -21,7 +21,7 @@ fifo() {
add() { add() {
buku --nostdin -a "$QUTE_URL" buku --nostdin -a "$QUTE_URL"
$TERMINAL --class badd,badd -e buku -w -1 $TERMINAL -a badd -e buku -w -1
fifo "message-info 'Added current url to buku'" fifo "message-info 'Added current url to buku'"
} }
@ -39,6 +39,7 @@ open() {
delete() { delete() {
bookmark=$(get_bookmark "Delete") bookmark=$(get_bookmark "Delete")
[ -z "$bookmark" ] && fifo "message-info 'No Bookmark selected!!!'" && exit
title=$(get_title "$bookmark") title=$(get_title "$bookmark")
buku --nostdin -d "$bookmark" --tacit buku --nostdin -d "$bookmark" --tacit
fifo "message-info 'Deleted bookmark $title.'" fifo "message-info 'Deleted bookmark $title.'"
@ -46,8 +47,9 @@ delete() {
edit() { edit() {
bookmark=$(get_bookmark "Edit") bookmark=$(get_bookmark "Edit")
[ -z "$bookmark" ] && fifo "message-info 'No Bookmark selected!!!'" && exit
fifo "message-info 'Editing bookmark $(get_title "$bookmark")'" fifo "message-info 'Editing bookmark $(get_title "$bookmark")'"
$TERMINAL --class badd,badd -e buku -w "$bookmark" $TERMINAL -a badd -e buku -w "$bookmark"
} }
main() { main() {