mirror of
https://github.com/golang/go
synced 2024-11-21 13:44:45 -07:00
misc: add zsh completion (using compctl)
R=golang-dev, rsc1, rsc CC=golang-dev https://golang.org/cl/2061042
This commit is contained in:
parent
724b66fb15
commit
815a67850c
14
misc/zsh/go
Normal file
14
misc/zsh/go
Normal file
@ -0,0 +1,14 @@
|
||||
# install in /etc/zsh/zshrc or your personal .zshrc
|
||||
|
||||
# gc
|
||||
prefixes=(5 6 8)
|
||||
for p in $prefixes; do
|
||||
compctl -g "*.${p}" ${p}l
|
||||
compctl -g "*.go" ${p}g
|
||||
done
|
||||
|
||||
# standard go tools
|
||||
compctl -g "*.go" gofmt
|
||||
|
||||
# gccgo
|
||||
compctl -g "*.go" gccgo
|
Loading…
Reference in New Issue
Block a user