26d807c50f
See https://github.com/ooni/probe-engine/issues/1181 While there, run `go fmt ./...`
21 lines
401 B
Go
21 lines
401 B
Go
package app
|
|
|
|
import (
|
|
"os"
|
|
|
|
"github.com/apex/log"
|
|
"github.com/ooni/probe-cli/v3/cmd/ooniprobe/internal/cli/root"
|
|
"github.com/ooni/probe-cli/v3/internal/version"
|
|
)
|
|
|
|
// Run the app. This is the main app entry point
|
|
func Run() {
|
|
root.Cmd.Version(version.Version)
|
|
_, err := root.Cmd.Parse(os.Args[1:])
|
|
if err != nil {
|
|
log.WithError(err).Error("failure in main command")
|
|
os.Exit(2)
|
|
}
|
|
return
|
|
}
|