Code Monkey home page Code Monkey logo

Comments (17)

nosami avatar nosami commented on May 16, 2024

So, you don't use the OmniSharp vimscript at all for your YCM plugin? I didn't realise that.

OmniSharp is more than just a completion plugin though. I couldn't see myself just wanting to use the completion side of OmniSharp without the other functionality (present and future) too.

It does kind of make sense for use with other editors... but nobody is using OmniSharp for that yet.

Thoughts?

from omnisharp-vim.

chtenb avatar chtenb commented on May 16, 2024

I would like to utilize other features of the NFactory library too, but I like to integrate as much as possible with existing vim plugins. This is because that makes things behave consistently throughout different filetypes, which is neat and userfriendly. Besides it reduces the risk of collision between plugins. Also it makes the software more likely to be used by others and less work to find and install.

I think that many of the omnisharp features can be integrated in plugins such as vim-autoformat, syntastic and of course YCM. The only thing I don't see being integrated is the refactoring/code actions part, but I may be wrong.

That being said, I wouldn't want you to quit your own integration into vim, but I merely would want to open up space for the previous. By splitting up the repo's, your vim integration stays intact.

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

I'm not sure that I agree but on the other hand I don't really have anything against the suggestion apart from the work involved. Leave it with me and I'll get onto it within the next few days. I don't get a lot of time to spend on this.

One thing you might want to consider is the ReloadSolution command. Very useful for keeping completions in sync when switching branches. It's much faster than stopping and restarting OmniSharp as the assemblies are already loaded, especially for large solutions.

I plan to add many more features in the weeks to come, mostly related to project management... stuff like creating projects, adding/deleting files to projects, integrated test runner etc... basically everything I need to get my day job done without using VS ;)

from omnisharp-vim.

chtenb avatar chtenb commented on May 16, 2024

Sounds good. I'm aware that there are C# specific things like project management that cannot be integrated into other plugins, simply because it is too C# specific. I'm not sure yet how to cope with that. I guess your vim stuff must come to aid there :) Looking forward to it.

from omnisharp-vim.

chtenb avatar chtenb commented on May 16, 2024

I've been thinking about this a little more. First I want to mention that refactoring actions can be integrated in YCM too, which I just deduced from this issue: ycm-core/YouCompleteMe#255 (comment). This proves my previous remark wrong.
Secondly, the main reason that I asked for splitting the vim files from the server files, is that installing Omnisharp as a bundle (beside YCM) now would result in having two completer plugins installed for C#, which would collide. (Same for syntastic.) If there is another way to avoid this, without having the user to explicitly configure stuff, that might be a (better) solution to this problem as well.

Ideally, (from my point of view) Omnisharp would just provide the NRefactory server and a vim plugin for project file management.
What do you think?

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

It would be pretty simple to detect YCM and disable the completion stuff in OmniSharp in that case.

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

OmniSharp and YCM didn't collide at all when I tried.

from omnisharp-vim.

chtenb avatar chtenb commented on May 16, 2024

"It would be pretty simple to detect YCM and disable the completion stuff in OmniSharp in that case."
That sounds like a plan actually. This may well be the easiest and best way to do it.

"OmniSharp and YCM didn't collide at all when I tried."
Weird enough Omnisharp and YCM don't collide currently, but that may change any moment.
Besides, it is just not good to have multiple plugins doing the same thing. That's asking for problems.

So summarizing the current idea: when a user wants to use YCM and omnisharp, he has to install both of them as a bundle, and Omnisharp will detect plugins that it can integrate with (currently just YCM), and disable its own functionality for that. Is that right?

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

Yes. Just these two lines would need disabling AFAIK.

setlocal omnifunc=OmniSharp#Complete
"don't autoselect first item in omnicomplete,show if only one item(for preview)
set completeopt=longest,menuone,preview

from omnisharp-vim.

chtenb avatar chtenb commented on May 16, 2024

Okay, how would you detect if YCM is installed?

from omnisharp-vim.

chtenb avatar chtenb commented on May 16, 2024

BTW, a second way to do it, is to disable the omnisharp completion from within the YCM plugin. But I don't know if that's reasonably possible.

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

No problem. It's no big deal for me to do it. Lots of OmniSharp users would want to use YCM but I'm not so certain about the other way around ;)

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

I removed those settings completely from the plugin as #34 . It's up to the user to add them in vimrc

from omnisharp-vim.

PaulCampbell avatar PaulCampbell commented on May 16, 2024

I would like to bump this issue. The server should be a separate repo.

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

@Chiel92 , @PaulCampbell The server component now lives here https://github.com/nosami/OmniSharpServer . Just need to sort out the submodule stuff and update the documentation.

Go crazy!

from omnisharp-vim.

PaulCampbell avatar PaulCampbell commented on May 16, 2024

Nice one man! Regarding submodules... Do you think it's neccessary? With the sublime plugin I intend to add the server executables to the git repo (and distributed package) . The server is a dependency of the plugin rather than a part of it. This may be different for the vim plugin...

Does raise the question about whether binaries should be versioned and downloadable :)

Seems a simpler solution though?

from omnisharp-vim.

nosami avatar nosami commented on May 16, 2024

@PaulCampbell Well, I wouldn't say it's necessary but I think I may be dealing with a different target audience than you. I suspect, but don't know, that most users of the vim plugin are using linux. Linux users expect source code.

from omnisharp-vim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.