Priority
(Low) Something is a little off
Description
Let's say I have a command with one boolean parameter
const options = globalOptionsZod
.extend({
enabled: zod.alias('e', z.boolean())
})
.strict();
When running the command without the parameter, CLI asks me to provide a value for the parameter
🌶️ Provide values for the following parameters:
√ enabled: 1
But it doesn't accept any value like 0, 1, true, or false and it fails with the error
Error: enabled: Expected boolean, received string
Steps to reproduce
Define zod schema with one boolean parameter for a command and try to run execute the command without the parameter.
Expected results
CLI accepts provided value for missing parameter.
Actual results
Error: enabled: Expected boolean, received string
Diagnostics
No response
CLI for Microsoft 365 version
v10.2.0
nodejs version
v20.8.1
Operating system (environment)
Windows
Shell
PowerShell
cli doctor
No response
Additional Info
No response
Priority
(Low) Something is a little off
Description
Let's say I have a command with one boolean parameter
When running the command without the parameter, CLI asks me to provide a value for the parameter
But it doesn't accept any value like
0,1,true, orfalseand it fails with the errorSteps to reproduce
Define zod schema with one boolean parameter for a command and try to run execute the command without the parameter.
Expected results
CLI accepts provided value for missing parameter.
Actual results
Diagnostics
No response
CLI for Microsoft 365 version
v10.2.0
nodejs version
v20.8.1
Operating system (environment)
Windows
Shell
PowerShell
cli doctor
No response
Additional Info
No response