diff --git a/.config/fish/functions/pb.fish b/.config/fish/functions/pb.fish index 8ce1476c..717bea20 100644 --- a/.config/fish/functions/pb.fish +++ b/.config/fish/functions/pb.fish @@ -46,7 +46,11 @@ id - select a paste and print its id" set -l args $argv[2..] switch $cmd case create - set -l output (hut paste create $args) + if test (count $args) = 0 + set output (hut paste create (fzf)) + else + set output (hut paste create $args) + end if not test $status = 0 echo 'Error creating paste!' false