From 815a67850c6680e0df558caadcda270a24f05615 Mon Sep 17 00:00:00 2001 From: Scott Lawrence Date: Mon, 30 Aug 2010 21:13:01 -0400 Subject: [PATCH] misc: add zsh completion (using compctl) R=golang-dev, rsc1, rsc CC=golang-dev https://golang.org/cl/2061042 --- misc/zsh/go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 misc/zsh/go diff --git a/misc/zsh/go b/misc/zsh/go new file mode 100644 index 0000000000..f17763d93f --- /dev/null +++ b/misc/zsh/go @@ -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