12 lines
611 B
Bash
Executable File
12 lines
611 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# Simple dmenu scipt to open a buku bookmark in a browser
|
|
|
|
. ~/.config/dmenu/config
|
|
|
|
[ "$1" = "open" ] && buku --nostdin -p -f5 | sed 's/\t/;/g' | column -t -s ';' | $DMENU -p "Open bookmark: " -i -l 10 | cut -d' ' -f1 | xargs -r buku --nostdin -o
|
|
|
|
[ "$1" = "edit" ] && buku --nostdin -p -f5 | sed 's/\t/;/g' | column -t -s ';' | $DMENU -p "Edit bookmark: " -i -l 10 | cut -d' ' -f1 | xargs -r "$TERMINAL" -e buku -w
|
|
|
|
[ "$1" = "delete" ] && buku --nostdin -p -f5 | sed 's/\t/;/g' | column -t -s ';' | $DMENU -p "Delete bookmark: " -i -l 10 | cut -d' ' -f1 | xargs -r -I % buku --nostdin -d % --tacit
|