Azure / iotedgedev

The Azure IoT Edge Dev Tool greatly simplifies your Azure IoT Edge development process. It has everything you need to get started and helps with your day-to-day Edge development.
https://aka.ms/iotedgedev
Other
160 stars 69 forks source link

fix: duplicate prompt messages #585

Closed roel4ez closed 1 year ago

roel4ez commented 2 years ago

Checklist

This checklist is used to make sure that common guidelines for a pull request are followed.

General guidelines

Description

Fixes #558

hi @marianan - This PR includes a commit to showcase the removal of the duplicate prompt message (only for subscription list right now). Let me know if you are ok with using this approach, and then I will work out the rest of the duplicate prompts.

Additional information

The problem seems to be that the method that sets the defaults is the one printing messages and when the prompt option is also set for the parameter, the default function gets called twice (see code).

The solution used here is to prompt the user in the default method instead of using the prompt click option.

Thanks @beandrad for the help

marianan commented 1 year ago

@roel4ez thanks for the PR and apologies for the late reply. I am ok with the approach, feel free to apply to the rest of the commands.

roel4ez commented 1 year ago

@roel4ez thanks for the PR and apologies for the late reply. I am ok with the approach, feel free to apply to the rest of the commands.

@marianan updated and applied to all arguments.