diff options
author | Martin Polden <mpolden@mpolden.no> | 2020-05-26 23:30:22 +0200 |
---|---|---|
committer | Martin Polden <mpolden@mpolden.no> | 2020-05-26 23:30:22 +0200 |
commit | a943e0260fdb1753180c79ef88a6a4c893fd2501 (patch) | |
tree | f28f9e81a9608ef84c5e01d16569e74f223abcc7 | |
parent | b19084a3623aa8392bd22a0699e430bea1a571c2 (diff) |
Remove unused option
-rw-r--r-- | git/git.go | 4 | ||||
-rw-r--r-- | main.go | 3 |
2 files changed, 3 insertions, 4 deletions
@@ -11,8 +11,8 @@ type Git struct { inheritIO bool } -func New(path string, inheritIO bool) (*Git, error) { - p, err := exec.LookPath(path) +func New(inheritIO bool) (*Git, error) { + p, err := exec.LookPath("git") if err != nil { return nil, err } @@ -16,7 +16,6 @@ import ( ) type CLI struct { - GitPath string `short:"g" long:"git" description:"Path to git executable" value-name:"PATH" default:"git"` Quiet bool `short:"q" long:"quiet" description:"Only print errors"` Dryrun bool `short:"n" long:"dryrun" description:"Print commands that would be run and exit"` Protocol string `short:"p" long:"protocol" description:"Use the given protocol when mirroring" choice:"ssh" choice:"https" choice:"git" default:"ssh"` @@ -98,7 +97,7 @@ func main() { log.Fatal(err) } - g, err := git.New(cli.GitPath, !cli.Quiet) + g, err := git.New(!cli.Quiet) if err != nil { log.Fatal(err) } |