~gpanders/dotfiles

ref: 5629911cfe9a2fc4e566bab14373aec451244000 dotfiles/fish/.config/fish/functions/buku.fish -rw-r--r-- 505 bytes
5629911cGreg Anders Fix bash syntax error in 'note' command 1 year, 11 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
function buku --description "Alias for buku --suggest. If no argument given, fuzzy find all bookmarks"
    set -q BUKU_COLORS; or set -Ux BUKU_COLORS "gCdxe"
    if test (count $argv) -eq 0; and command -sq fzy
        set -l website (buku --print --format 5 | column -ts'$'\t | fzy)

        for i in $website
            set -l index (echo "$i" | awk '{print $1}')
            buku --print "$index"
            buku --open "$index"
        end
    else
        command buku --suggest $argv
    end
end