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

A breaking change was introduced by mistake #154

Closed
ImSingee opened this issue Mar 29, 2023 · 1 comment
Closed

A breaking change was introduced by mistake #154

ImSingee opened this issue Mar 29, 2023 · 1 comment

Comments

@ImSingee
Copy link
Contributor

What version of GCI are you using?

v0.10.1

Reproduce Steps

1. Run `gci write -s 'standard,default' path1` which is valid in old versions
2. An error occurred

What did you expect to see?

It should work as before

Some notes

This is because, in PR #142, the type of the Section flag is changed from StringSlice to StringArray. The previous one allows --flag A,B to be seen as equal to --flag A --flag B but the latter does not.

There are at least two ways to optimize the situation:

  1. Change the new syntax Prefix(A,B) to Prefix(A|B) (or something similar) which does not require a breaking change to existing usage
  2. Mark the v0.10.0 release as a breaking change

However, both are not done; a breaking change is silently introduced.

Because v0.10.0 is also released, so I think it may not good to change the new prefix grammar. But at least, this change should be highlighted in the v0.10.0 release.

@daixiang0
Copy link
Owner

@ImSingee good catch! Could you help update README then I will create a new release to highlight it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants