Commits

Yoshifumi YAMAGUCHI committed 4111303

added godef and gocode support to goof make

Comments (0)

Files changed (1)

shellscripts/goenvwrapper.sh

 
   local envhome
   local args
+  local gocode_flag=false
+  local godef_flag=false
   until [ -z "$1" ]; do
     case "$1" in
       "-go" | "--go")
         args="$args -gae"
         shift
         ;;
+      "-gocode" | "--gocode")
+        gocode_flag=true
+        shift
+        ;;
+      "-godef" | "--godef")
+        godef_flag=true
+        shift
+        ;;
       *)
         envhome="$GOENVHOME/$1"
         shift
     source "$envhome/activate"
   fi
   cd "$envhome"
+  
+  if $gocode_flag; then
+    eval `go get -u github.com/nsf/gocode`
+  fi
+
+  if $godef_flag; then
+    eval `go get code.google.com/p/rog-go/exp/cmd/godef`
+  fi
   return 0
 }