Commit ede6655
authored
feat: update color usage, telemetry activation logic, and command/util dependencies (#3646)
* deps: update @heroku-cli/command and @heroku/heroku-cli-util
- Update @heroku-cli/command from ^12.2.2 to ^12.3.1
- Update @heroku/heroku-cli-util from ^10.7.0 to ^10.8.0
- Replace deprecated color.dim() calls with color.gray() and color.inactive()
- Update telemetry initialization to use isTelemetryEnabled() helper
- Standardize color method usage across all command files
* force colors to be true for now
* fix tests and force color in unit tests
* set force_colors in init.mjs
* Fix pg:copy tests to pass locally
* enables telemetry for windows in testing
* test: fix failing tests after dependency updates
- Fix telemetry tests to enable telemetry in test environment
- Set ENABLE_WINDOWS_TELEMETRY for Windows CI compatibility
- Add test to verify telemetry is disabled by default on Windows
- Properly save/restore environment variables
- Fix spaces/format test for updated color.gray() ANSI code
- Fix pg:copy test to handle line wrapping differences between CI and local
- Normalize whitespace in warning message assertions
- Handle oclif's warning prefix (›) in wrapped output
- Set FORCE_COLOR=3 in test init to ensure consistent color output
All tests now pass in local, Linux CI, and Windows CI environments.
* style: add blank line for import grouping in telemetry-manager
* fix linting
* test: handle Windows warning prefix (») in pg:copy test
The oclif warning prefix differs between platforms:
- Unix/Linux/macOS: › (single angle quote)
- Windows: » (double angle quote)
Updated the regex to handle both characters when normalizing output.
* fix: prevent telemetry worker from keeping parent process alive
The telemetry worker was spawned with stderr set to 'inherit', which created
a persistent file descriptor reference preventing the parent CLI process from
exiting until the worker completed. This caused the CLI to hang for users.
Changes:
- Only inherit stderr when DEBUG is set (for development)
- Worker explicitly closes stderr before exiting (in DEBUG mode)
- Uses setImmediate to allow stderr to flush before closing
* fix linting1 parent b9b8fed commit ede6655
File tree
44 files changed
+671
-490
lines changed- bin
- src
- commands
- addons
- data
- maintenances
- pg
- credentials
- notifications
- pg
- backups
- credentials
- ps
- releases
- spaces
- drains
- peerings
- trusted-ips
- lib
- analytics-telemetry
- data
- ps-exec
- run
- test
- helpers
- unit
- analytics-telemetry
- commands/pg
- lib/spaces
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
44 files changed
+671
-490
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | | - | |
5 | 3 | | |
6 | 4 | | |
7 | 5 | | |
| |||
14 | 12 | | |
15 | 13 | | |
16 | 14 | | |
17 | | - | |
18 | | - | |
| 15 | + | |
19 | 16 | | |
20 | | - | |
| 17 | + | |
21 | 18 | | |
22 | 19 | | |
23 | 20 | | |
| |||
26 | 23 | | |
27 | 24 | | |
28 | 25 | | |
29 | | - | |
| 26 | + | |
30 | 27 | | |
31 | 28 | | |
32 | 29 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| |||
0 commit comments