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

Breaking change related to short options in 6.0.0? #1318

Closed
martinlevesque opened this issue Jul 27, 2020 · 3 comments
Closed

Breaking change related to short options in 6.0.0? #1318

martinlevesque opened this issue Jul 27, 2020 · 3 comments
Labels
docs README (or other docs) could be improved

Comments

@martinlevesque
Copy link

martinlevesque commented Jul 27, 2020

Hey,

Previously the following:

commander
    .command('logs')
    .option("-n <nb-lines>", "Number of lines")
    .description('Print logs')
    .action(async function(opts) {
      ....

The option n was populated in opts.N (note the capital letter), but now it is no more available opts.N but is now available in opts.n. Is it a bug or the correct new behaviour?

@martinlevesque martinlevesque changed the title Breaking change related to short options? Breaking change related to short options in 6.0.0? Jul 27, 2020
@shadowspawn
Copy link
Collaborator

Correct new behaviour. See #1249 #1256

(I didn't call out this change specifically in the release notes, partly because I wasn't sure how many people were using short options.)

@shadowspawn shadowspawn added the docs README (or other docs) could be improved label Jul 27, 2020
@martinlevesque
Copy link
Author

Sounds good thanks. I think it's better with lower case with the new version, would have been better to have a breaking change line in the release note I think, thanks anyway.

@shadowspawn
Copy link
Collaborator

shadowspawn commented Jul 28, 2020

Added breaking note to CHANGELOG and Release Notes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs README (or other docs) could be improved
Projects
None yet
Development

No branches or pull requests

2 participants