vknabel / vscode-swiftformat

SwiftFormat for VS Code
https://marketplace.visualstudio.com/items?itemName=vknabel.vscode-swiftformat
MIT License
39 stars 7 forks source link

add windows suport #30

Open insinfo opened 9 months ago

insinfo commented 9 months ago

I have swift 5.9 and swiftformat 0.52.7 installed but when I use the format option in VS Code it deletes all source code

image

image

image

vknabel commented 9 months ago

Thanks for the report! As I don't have access to a windows system, I am unable to reproduce your problem.

As debugging windows issues requires lots of ping pong with a tester, I would appreciate a pull request by any volunteer.

MChriss12 commented 7 months ago

Still a bug. It deletes all the source code when trying to autoformat on save.

vknabel commented 7 months ago

Correct. I haven’t done anything, because as mentioned, I don’t have access to a device running windows.

I would appreciate a pull request by any volunteer.

Alternatively I could simply disable all formatting on windows.

oskargargas commented 6 months ago

Take a look at https://github.com/vknabel/vscode-apple-swift-format/issues/40#issuecomment-1870430614 same fix works for swiftformat too