Implement time-boxed CLI telemetry with opt-out controls#4927
Implement time-boxed CLI telemetry with opt-out controls#4927arturcic wants to merge 4 commits intoGitTools:next/v7from
Conversation
Implement a telemetry pipeline to collect redacted CLI usage data for OSS design decisions. Users can opt out via environment variables `DO_NOT_TRACK`, `GITVERSION_TELEMETRY_OPTOUT`, or the `--telemetry-opt-out` flag.
Embed release dates in assembly metadata during build and disable telemetry if the window has expired or metadata is missing.
Detect the current CI environment and identify whether the CLI was invoked directly or via GitVersion.MsBuild to better understand usage patterns.
…older Organize the GitVersion.App project structure by grouping telemetry components into their own directory.
|
|
Here is a bit more context: Implement time-boxed, privacy-focused telemetry for the GitVersion CLI. Introduce a telemetry pipeline that collects narrow CLI usage data for a 3-month window following a release. This system includes automated redaction of sensitive paths and credentials while providing multiple opt-out mechanisms via environment variables and CLI flags. Changes What is left is to decide on the backend where all the usage is saved, preferable with some dashboard we can use to see the different usage types. This is a follow up on the refactoring done for v7 where the new POSIX compliant cli was introduced. @asbjornu @gep13 @HHobeck, do you mind to have a look and suggest a backend solution for this? Thank you. |



Description
Introduces an optional telemetry pipeline to collect CLI usage data, featuring automated redaction of paths and sensitive values. Collection is restricted to a 3-month window following the release date and supports multiple opt-out mechanisms including environment variables and a CLI flag.
Related Issue
Resolves #XYZ
Motivation and Context
This change helps maintainers make data-driven OSS design decisions by understanding common CLI patterns and environment contexts while preserving user privacy through strict redaction and transparency notices.
How Has This Been Tested?
Tested via new unit test suites covering argument parsing, redaction logic, environment-based opt-out, and release window validation.
Screenshots (if appropriate):
Checklist: