-
Notifications
You must be signed in to change notification settings - Fork 818
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
WorkspaceEdit and File Level Operations #272
Comments
What about a simple |
I agree that we should expand the WorkspaceEdit with a resourceChanges property which allows for the following resource operations:
This would solve the rename refactoring as as well. |
A proposal is highly appreciated. |
@dbaeumer I think this one needs a |
Agree. |
@dbaeumer I have seen there is support for resource change now in LSP. However, what's missing from my point of view is the creation of folders. If I have a rename or a delete, I know whether I am dealing with a folder or a file, But in a create, I have no way of knowing. Shouldn't "isFolder" be added to CreateFileOptions? The spec even references the possiblity to change folders, but it's not in the code. |
@tsmaeder correct :-). All I can recommend right now is to create a file in the folder and then delete the file. I will keep the request open to support creating a folder. Will very likely be an additional property / param type: 'file' | 'folder' |
See also microsoft/vscode#62663 |
@dbaeumer Either way, it is not decent workaround at this time. |
Refactor package name is really an important feature for Java language, without creating/deleting folder support in LSP level, it's hard to bring this feature to jdt.ls. @dbaeumer is there any update about this issue? Or any help i can provide to solve it? thanks. |
@testforstephen thanks for offering your help. Things needed to be done to make this work:
Should not be too complicated. I would start with the VS Code work and then add the LSP resource change. |
great, thanks for the explanation. Looking forward to see it's solved. |
This got added a while back ago. |
A rename operation, for example returns a WorkspaceEdit operation. However, when renaming a Java class, for example, I expect the file to be renamed as well. Is there a way to express that in LSP?
The text was updated successfully, but these errors were encountered: