(dir string, bin string, useGodep bool, wd string, buildArgs []string)
| 24 | } |
| 25 | |
| 26 | func NewBuilder(dir string, bin string, useGodep bool, wd string, buildArgs []string) Builder { |
| 27 | if len(bin) == 0 { |
| 28 | bin = "bin" |
| 29 | } |
| 30 | |
| 31 | // does not work on Windows without the ".exe" extension |
| 32 | if runtime.GOOS == "windows" { |
| 33 | if !strings.HasSuffix(bin, ".exe") { // check if it already has the .exe extension |
| 34 | bin += ".exe" |
| 35 | } |
| 36 | } |
| 37 | |
| 38 | return &builder{dir: dir, binary: bin, useGodep: useGodep, wd: wd, buildArgs: buildArgs} |
| 39 | } |
| 40 | |
| 41 | func (b *builder) Binary() string { |
| 42 | return b.binary |
nothing calls this directly
no outgoing calls
no test coverage detected