github.com/joey-fossa/fossa-cli@v0.7.34-0.20190708193710-569f1e8679f0/buildtools/okbuck/cmd.go (about)

     1  package okbuck
     2  
     3  import (
     4  	"github.com/fossas/fossa-cli/errors"
     5  	"github.com/fossas/fossa-cli/exec"
     6  )
     7  
     8  func Cmd(args ...string) (string, error) {
     9  	out, _, err := exec.Run(exec.Cmd{
    10  		Name: "./buckw",
    11  		Argv: args,
    12  	})
    13  
    14  	if err != nil {
    15  		return out, errors.Wrapf(err, "Could not run `buckw %+v` within the current directory", args)
    16  	}
    17  	return out, nil
    18  }