Enter Telemetry (#4482)

* Send telemetry to segment

* Add tests and other properties

* Add comments

* Fix fmt

* Add telemetry dev key

* Add non-test related changes requested to the PR and add consenttelemetry prompt

* Handle prompt while running tests

* First attempt at fixing unit job failure

* Modify tests as requested

* Stop prompting when preference is called

* Fix comments

* Add more unit tests and integration test(WIP)

* Fix failing tests

* Stop prompting when help is called

* Make tests more verbose

* Add Usage data doc

* Add segment key

* Add a better usage doc

* Add comments, move tests and other requested changes

* Fix comments and remove focus

* Add set ConsentTelemetry unit tests

* Change want from string to bool

* Fix failing integration test

* Fix failing operator hub test

* Fix failing devfile integration test

* Fix tests failing due to cmdwrapper WithEnv

Co-authored-by: Dharmit Shah <shahdharmit@gmail.com>
This commit is contained in:
Parthvi Vala
2021-03-26 17:13:09 +05:30
committed by GitHub
parent 45d4098e38
commit c98445f8bb
102 changed files with 4642 additions and 48012 deletions

View File

@@ -53,13 +53,14 @@ func main() {
return
}
// Call commands
// checking the value of updatenotification in config
// before proceeding with fetching the latest version
cfg, err := preference.New()
if err != nil {
util.LogErrorAndExit(err, "")
}
// Call commands
// checking the value of updatenotification in config
// before proceeding with fetching the latest version
if cfg.GetUpdateNotification() {
updateInfo := make(chan string)
go version.GetLatestReleaseInfo(updateInfo)