-
Notifications
You must be signed in to change notification settings - Fork 145
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
dotnet format logs no change nessesary with dotnet
#327
Comments
have the same issue with latest formatter.nvim |
Hmm yeah I'm able to replicate this as well. I wonder if it's something with the formatters arguments |
I'm facing the same issue with rubocop, but I can't debug properly. |
I'm changing the files. It seems the stdout is not being setted to the output. So it is equal to the input and the error message says the no changes happened. |
This code is not running if ignore_exitcode or data == 0 then
if current_output == nil then
current_output = { "" }
end
log.info(string.format("Finished running %s", name))
output = transform and transform(current_output) or current_output
end
|
I changed and it worked @Rikthepixel @mhartington if ignore_exitcode or data ~= 0 then
if current_output == nil then
current_output = { "" }
end
log.info(string.format("Finished running %s", name))
output = transform and transform(current_output) or current_output
end I don't know the impacts, but I will run the tests and create a PR later. |
The PR was reverted |
Which configuration?
Type (custom or builtin): builtin
Filetype: cs
Formatter: dotnetformat
Configuration(s):
Builtin dotnet format
Attempted custom configuration with ignore_exitcode and no_append
Expected behavior
When the formatter is ran the contents of the file should be changed the and result in the same changes as running
dotnet format whitespace --include .\Test.cs
in the commandline.Initial file content
File content after format
Actual behaviour
When the formatter is ran,
formatter.nvim
logs that nothing has changed. When checking the tempfile it does seem that it hasn't changed. Though when manuallydotnet format whitespace --include .\Test.cs
the it does get formatted correctly.Additional context
formatter.nvim
logsno change nessesary with dotnet
. Which seems to mean that the tempfile hasn't changed. I tried to modify the plugin to try to debug it, though it just confirmed what the log said. Maybe theformatter.nvim
is reading the file out beforedotnet format
is finished formatting?The text was updated successfully, but these errors were encountered: