-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Support list of files/directories to be ignored by fmt and lint via a .denoignore
file
#12916
Comments
You can include/exclude directories from |
@GJZwiers, you're right and with the automatic lookup planned for the upcoming releases this will be quite close to the desired feature. I think |
@GJZwiers is right, the configuration file is the way to do it, but you can also add
This won't happen, we will support only a single configuration file and don't intend to add custom ignore files or consider |
@bartlomieju for a package.json style global config you have to read a manual, Besides that adding "// deno-fmt-ignore-file" renders the json invalid it is not an option if the tool aggregates or caches JSON data from other sources. Also, does the But you seem to be in a position to know what the community will and will not support and what its intentions are. To me, this doesn't sound like the open, welcoming, diverse, inclusive, and healthy community the code of conduct wants to achieve. What gives you this sense of authority in the matter? Has this been previously discussed? Giving references would help me understand your answer. |
That's a good point, indeed you can't add a comment to a plain JSON file.
It doesn't do that automatically, but you can add it after bundling (though I see no reason not to add them automatically). Bundled files are artifacts produced in a build step and such files are not usually linter/formatted afterwards. Do you have a use case in mind where you want to lint bundled file?
If community wants to use |
.denoignore
file
I exactly don't want to lint them. Consider a simple project structure for a web-app.
The generated I see that One can live without |
As mentioned, this is already supported via a config file by doing Alternatively, files/directories may be ignored on the cli by specifying an
See the
I've looked into implementing directory based files such as The convenience of the current configuration file will improve once Due to the complexity of this issue and the other solutions that exist, it's not something that we want to maintain as maintainers. For that reason, I'm going to close this issue. |
I hate seeing deno losing its simplicity. This isn't mainly about having to write 12-15 lines of config rather than just 1: By effectively coercing users to put a prominent So while dismissing this proposal sounds like reducing configuration options, it effectively promoted full-fledged project specific configurations. |
I just found this tread as I needed to ignore NPM folder created by DNT lib. |
I would like to be able to specify directories and/or file patterns that shall be ignored by
deno fmt
anddeno lint
. This could be achieved with a.denoignore
file similar to.gitignore
.Motivation:
deno lint
.The text was updated successfully, but these errors were encountered: