@vatio-ai/cli 0.124.0 → 0.125.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/telemetry.mjs +5 -1
- package/package.json +1 -1
package/lib/telemetry.mjs
CHANGED
|
@@ -145,7 +145,11 @@ function noticeOnce() {
|
|
|
145
145
|
export function commandLabel(command, args = []) {
|
|
146
146
|
if (!command) return "help";
|
|
147
147
|
const sub = args[0];
|
|
148
|
-
|
|
148
|
+
if (SUBCOMMANDS[command]?.includes(sub)) return `${command} ${sub}`;
|
|
149
|
+
// A command the CLI does not have is kept when it is a word an agent
|
|
150
|
+
// guessed (`whoami`), and not when it is a sentence or a value someone
|
|
151
|
+
// passed where the command goes.
|
|
152
|
+
return /^[\w@.:\/-]{1,40}$/.test(command) ? command : "unknown";
|
|
149
153
|
}
|
|
150
154
|
|
|
151
155
|
export function clientHeaders() {
|