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

Deno fmt command does not complain about missing files #3915

Closed
srackham opened this issue Feb 7, 2020 · 4 comments
Closed

Deno fmt command does not complain about missing files #3915

srackham opened this issue Feb 7, 2020 · 4 comments

Comments

@srackham
Copy link

srackham commented Feb 7, 2020

$ deno fmt non-existant-file.ts
Formatted 0 files in 213ns

$ echo $?
0

$ deno --version
deno 0.32.0
v8 8.1.108
typescript 3.7.2

Is this the expected behaviour?

@nayeemrmn
Copy link
Collaborator

Maybe we should handle this like the test runner; non-zero exit code if there are no matching files.

@srackham
Copy link
Author

srackham commented Feb 7, 2020

@nayeemrmn: That would still allow file name typos to slip through unnoticed e.g.

deno fmt non-existent-file.ts existing-file.ts  # 1 file formatted.

@kevinkassimo
Copy link
Contributor

I think a basic solution is simply to warn "No file matching {...}" when we get empty paths after running glob on a pattern

@bartlomieju
Copy link
Member

Fixed in #3988 and released in v0.33.0

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.

4 participants