-
Notifications
You must be signed in to change notification settings - Fork 93
Virtual File System #15
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
Conversation
About to change to use a standard handler with Uri -> IO VirtualFile callback
Need to verify the sort order for changes
One problem with depending on the yi-rope package is that it is GPL. IANAL, so I'm not sure if that means that this package must be GPL too. This: http://stackoverflow.com/questions/11819831/including-gpl-external-library-in-mit-code seems to suggest it does. |
My personal, and entirely selfish preference, is to keep this library MIT so that I can use it in the VHDL language server I am building and sell it in the future. |
Yes, I was wondering about that too. I discussed it on IRC with some people, who seemed to think that BSD3 and GPL are compatible. I am not personally worried about licensing, so would gladly change the license here to match something. @adamwalker what are your views on that? Given you are a contributor. |
And BSD3? Because I am quite keen to have changes managed here, and YiRope is good for that. I imagine it should be possible to pass the types/functions in as part of the initialization, if all else fails. Except the change management is particularly easy with YiRope. |
Yeah - anything that uses GPL code must be GPL. It also might be possible to not have the rope stuff as part of the framework but instead provide a separate library that the user calls from within the file opened/changed/saved callbacks that does all the work of keeping track of the contents of URIs. But, thats not as nice as what you currently have. It's up to you really. Just consider that using yi-rope prevents commercial uses of this library. |
Well, we have identified a workaround that could be made to enable commercial use and strip out the GPL part. So I suggest we leave it as now and let a future commercial user do that. Unless you want to do a PR on it for that functionality now already. It is no big deal for me, I am not personally planning commercial use, but I am not keen to do much work for the benefit of commercial users only :). If it would help, I am happy to change the license too, if you have a preference. |
And that means any company that wants to ship a language server will have to ignore this package and build their own from scratch. |
And from GHC 8.2 we can make the Yi.Rope package a backpack specification, so you can plug in anything that meets the signature. |
@adamwalker Are you happy with the proposed workaround, if commercial use is required? I would like to merge this. |
Yep. The backpack proposal sounds good. |
And I captured the required cleanup in an issue, for any future commercial users. See #16 |
Introduces a virtual file system, in the sense that it processes the
textDocument/didOpen
,textDocument/didChange
andtextDocument/didClose
notifications to replicate the state of a file being edited in the IDE.This is accesed in the
Handler
via a new field with signaturewhere a
VirtualFile
is defined as