abinfo "Generating shell completions ..."
for i in bash fish zsh; do
    "$PKGDIR"/usr/bin/jj util completion $i > "$SRCDIR"/jj-completions.$i
done

abinfo "Installing shell completions ..."
install -Dvm644 "$SRCDIR"/jj-completions.bash "$PKGDIR"/usr/share/bash-completion/completions/jj
install -Dvm644 "$SRCDIR"/jj-completions.fish "$PKGDIR"/usr/share/fish/vendor_completions.d/jj.fish
install -Dvm644 "$SRCDIR"/jj-completions.zsh "$PKGDIR"/usr/share/zsh/site-functions/_jj
