Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add --format option to multipass version command #2020

Closed
cjp256 opened this issue Mar 22, 2021 · 4 comments
Closed

Add --format option to multipass version command #2020

cjp256 opened this issue Mar 22, 2021 · 4 comments

Comments

@cjp256
Copy link

cjp256 commented Mar 22, 2021

Describe the bug
Multipass sometimes logs unrelated messages to stdout. When parsing stdout information, this can lead to undesirable behavior.

To Reproduce
Install multipass 1.5 for Windows.

Run multipass version

How, and what happened?

>multipass version 2>stderr.txt
multipass  1.5.0+win
multipassd 1.5.0+win

###########################################################################################
New Multipass 1.6.2 release
Now with bridged networking support

Go here for more information: https://github.com/CanonicalLtd/multipass/releases/tag/v1.6.2
###########################################################################################

Expected behavior
The extra outputs should be logged to stderr to allow for more reliable parsing of stdout.

@cjp256 cjp256 added the bug label Mar 22, 2021
@Saviq
Copy link
Collaborator

Saviq commented Mar 22, 2021

I'd say we should have a --format for multipass version instead, so you can safely parse that.

@Saviq Saviq changed the title use stderr for unrelated outputs Add --format option to multipass version command Mar 22, 2021
@cjp256
Copy link
Author

cjp256 commented Mar 22, 2021

I'd say we should have a --format for multipass version instead, so you can safely parse that.

Even better 👍

@surahman
Copy link
Contributor

With respect to #2077 :
I made the modifications to include the --format flag and it will only be recognised in conjunction with the -V and --version cmdl flags. Corrected a typo with a missing quote in the help info string.

bors bot added a commit that referenced this issue Aug 2, 2021
2077: [cli] Version Information Formatter r=Saviq a=surahman

In response to issue #2020
Outputting the updates available notice message to `stderr` until I read up on _**QT Command Line Parser**_ and set up flag options.

Co-authored-by: Saad Ur Rahman <saad.ur.rahman@gmail.com>
bors bot added a commit that referenced this issue Aug 2, 2021
2077: [cli] Version Information Formatter r=Saviq a=surahman

In response to issue #2020
Outputting the updates available notice message to `stderr` until I read up on _**QT Command Line Parser**_ and set up flag options.

Co-authored-by: Saad Ur Rahman <saad.ur.rahman@gmail.com>
@Saviq
Copy link
Collaborator

Saviq commented Oct 18, 2021

Fixed in #2077

@Saviq Saviq closed this as completed Oct 18, 2021
@Saviq Saviq added this to the v1.8.0 milestone Oct 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants