Skip to content

Commit 9769533

Browse files
aosc-buildit-botMingcongBai
authored andcommitted
ast-grep: update to 0.39.6
Install completions for Bash, Fish, and Zsh. Co-authored-by: 白铭骢 (Mingcong Bai) (@MingcongBai) <[email protected]>
1 parent fc10cb7 commit 9769533

File tree

2 files changed

+17
-6
lines changed

2 files changed

+17
-6
lines changed
Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,21 @@
11
abinfo "Setting asg as ast-grep symlink ..."
22
ln -sv ast-grep "$PKGDIR"/usr/bin/asg
33

4-
abinfo "Removing xtask binary ..."
5-
rm -fv "$PKGDIR"/usr/bin/xtask
4+
abinfo "Generating shell completions ..."
5+
for i in bash fish zsh; do
6+
"$PKGDIR"/usr/bin/ast-grep completions $i \
7+
> "$SRCDIR"/ast-grep.$i
8+
"$PKGDIR"/usr/bin/asg completions $i \
9+
> "$SRCDIR"/asg.$i
10+
done
611

7-
abinfo "Installing completions ..."
12+
abinfo "Installing shell completions ..."
813
mkdir -pv "$PKGDIR"/usr/share/bash-completion/completions
9-
"$PKGDIR"/usr/bin/ast-grep completions > "$PKGDIR"/usr/share/bash-completion/completions/ast-grep
10-
"$PKGDIR"/usr/bin/asg completions > "$PKGDIR"/usr/share/bash-completion/completions/asg
14+
for i in ast-grep asg; do
15+
install -Dvm644 "$SRCDIR"/${i}.bash \
16+
"$PKGDIR"/usr/share/bash-completion/completions/${i}
17+
install -Dvm644 "$SRCDIR"/${i}.fish \
18+
"$PKGDIR"/usr/share/fish/vendor_completions.d/${i}.fish
19+
install -Dvm644 "$SRCDIR"/${i}.zsh \
20+
"$PKGDIR"/usr/share/zsh/site-functions/_${i}
21+
done

app-devel/ast-grep/spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VER=0.38.2
1+
VER=0.39.6
22
SRCS="git::commit=tags/$VER::https://github.com/ast-grep/ast-grep"
33
CHKSUMS="SKIP"
44
CHKUPDATE="anitya::id=361439"

0 commit comments

Comments
 (0)