Clarify that `DO_NOT_TRACK` only disables telemetry if `1` or `true`

Đang mở Phù hợp với người mới
#45,957 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
1/5
Thời gian dự kiến
Dưới một giờ
Mức phù hợp với người mới
90/100
Loại issue
Tài liệu
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
github, shell
Lĩnh vực
cli, documentation

Hướng nghiên cứu

Mở bài viết về telemetry của GitHub CLI được liên kết trên docs.github.com và tìm phần về các biến môi trường “How to opt out”. So sánh cách diễn đạt với tham chiếu cli/cli internal/telemetry/telemetry.go được liên kết, ở khoảng dòng 128, sau đó làm rõ các giá trị DO_NOT_TRACK nào sẽ tắt telemetry và xác minh rằng ví dụ vẫn chính xác.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

content triage
Code of Conduct
What article on docs.github.com is affected?

https://docs.github.com/en/github-cli/github-cli/github-cli-telemetry#how-to-opt-out

What part(s) of the article would you like to see updated?

The section on environment variables currently looks like this:

Environment variables:

export GH_TELEMETRY=false

Any falsy value works: 0, false, disabled, or an empty string. You can also use the DO_NOT_TRACK convention:

export DO_NOT_TRACK=true

Saying that any falsy value works for GH_TELEMETRY right before introducing DO_NOT_TRACK can create the implication that any truthy value would be accepted for DO_NOT_TRACK. I believe this is not the case though; it looks like DO_NOT_TRACK must be 1 or true. It would be nice to clarify this.

It also seems like most people set DO_NOT_TRACK to 1 anyway, so it would be good to be explicit for the opposite reason too; we don't want people to assume that only true is accepted.

Additional information

No response

Ngôn ngữ chính
TypeScript
Star
20.9k
Fork
68.8k
Merge trung bình
13 giờ 55 phút
Pull request đã merge (30 ngày)
105

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của github/docs

Tất cả issue của github/docs

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.