github.com/lenfree/buffalo@v0.7.3-0.20170207163156-891616ea4064/buffalo/cmd/generate/gocmd.go (about) 1 package generate 2 3 import "os/exec" 4 5 // GoInstall compiles and installs packages and dependencies 6 func GoInstall(pkg string) *exec.Cmd { 7 args := []string{"install"} 8 args = append(args, pkg) 9 return exec.Command("go", args...) 10 } 11 12 // GoGet downloads and installs packages and dependencies 13 func GoGet(pkg string) *exec.Cmd { 14 args := []string{"get"} 15 args = append(args, pkg) 16 return exec.Command("go", args...) 17 }