Draft of FsProj Enhancements #333
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is a (very) rough draft of some FsProj and eglot enhancements I've been playing with.
I'd love to get some general feedback on the approach and see what folks appetite would be for bringing something like this in.
Pain points this solves for my workflow
slneglot uses the project integration and ends up finding thefsprojfirst, even if there's aslnfile further up the directory tree, which means I end up running multiple copies ofFsAutoCompletewhen editing client/server projectsfsprojfile during development I have to kill/restart eglot/FsAutoComplete for the changes to be detectedGeneral layout of my approach, and some reasoning.
The solution file issue is straightforward, I've extended the project/sln search to first run a search for a
slnfile, and then to fallback to either anfsprojfile if aslnfile cannot be found see hereFor adding/removing
fsfiles is accomplished via pretty straightforward modifications toeglot-fsharpitself here. Renaming is similar, although in that case I save the buffer first, and then open the alternative file once the operation is completed.The changing of the file order is a bit more complicated. I opted to create a new
fsproj-modebecause it simplifies the implementation oftabulated-list-mode, however this mode isn't intended to be accessed from anfsprojfile, but rather launched from anfsfile with eglot running, because otherwise getting the running eglot session (or joining one) seems tricky to manage. You can open the buffer for with the commandfsproj-list-filesand then use u/d to move/change the file order.