1 # Contributor: Dave Reisner <d@falconindy.com>
6 pkgdesc="An autocompletion/refactoring daemon for the Go programming language (for use in Vim)"
8 url="http://github.com/nsf/gocode"
16 _gitroot="git://github.com/nsf/gocode.git"
21 msg "Connecting to GIT server...."
23 if [[ -d $_gitname ]] ; then
24 ( cd "$_gitname" && git pull origin; )
25 msg "The local files are updated."
27 git clone "$_gitroot" "$_gitname"
30 msg "GIT checkout done or server timeout"
31 msg "Starting make..."
33 rm -rf "$srcdir/$_gitname-build"
34 git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
35 cd "$srcdir/$_gitname-build"
41 cd "$srcdir/$_gitname-build"
43 install -Dm755 gocode "$pkgdir/usr/bin/gocode"
44 install -Dm644 vim/autoload/gocomplete.vim "$pkgdir/usr/share/vim/vimfiles/autoload/gocomplete.vim"
45 install -Dm644 vim/ftplugin/go.vim "$pkgdir/usr/share/vim/vimfiles/ftplugin/go.vim"