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

List instead of regex #393

Closed
LisPrzemyslaw opened this issue Jul 25, 2024 · 1 comment · Fixed by #402
Closed

List instead of regex #393

LisPrzemyslaw opened this issue Jul 25, 2024 · 1 comment · Fixed by #402
Assignees

Comments

@LisPrzemyslaw
Copy link

Right now for excluding the files it is required to use regex. For the other tools like flake8 the exclude contain a list of paths which should be excluded.
The regex is really difficult to read write and also it is hard to hold it inside the .toml file. The regex pattern contains also \, \\, \/ which are not allowed in a config files, you have to makes workaround for it. Also the regex is not the best option for the paths.

The solution can be a list which holds a paths and also file names. Then it easy to read and it is definitely more user friendly.
Example: excluded=["src/design/*", "docs/*", "src/my_file.py"]

@jshwi jshwi self-assigned this Jul 28, 2024
@jshwi jshwi linked a pull request Jul 31, 2024 that will close this issue
jshwi added a commit that referenced this issue Jul 31, 2024
Signed-off-by: Stephen Whitlock <stephen@jshwisolutions.com>
@jshwi
Copy link
Owner

jshwi commented Jul 31, 2024

Hi @LisPrzemyslaw
I've added a new option, excludes as well as exclude
excludes, as in excludes one or more paths
I couldn't add it instead of as it could break for people
Both can be used alone, or with each other
At least all the above should work, but please let me know if you spot a bug!
This will be available now under 0.60.0
Thanks!
Stephen

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

Successfully merging a pull request may close this issue.

2 participants