Skip to content

Commit

Permalink
exec: try running local binary first
Browse files Browse the repository at this point in the history
  • Loading branch information
xypwn committed Mar 21, 2024
1 parent 9881fc5 commit 09ba38b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions exec/exec.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ func NewRunner() *Runner {
}

func (r *Runner) Add(name string, defaultArgs ...string) (found bool) {
path, err := exec.LookPath(name)
path, err := exec.LookPath("./" + name)
if err != nil {
if path, err = exec.LookPath("./" + name); err != nil {
if path, err = exec.LookPath(name); err != nil {
return false
}
}
Expand Down

0 comments on commit 09ba38b

Please sign in to comment.