Skip to content
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

Does this still work with vim8? #19

Closed
aVikingTrex opened this issue Nov 16, 2019 · 20 comments
Closed

Does this still work with vim8? #19

aVikingTrex opened this issue Nov 16, 2019 · 20 comments
Assignees
Labels
bug Something isn't working

Comments

@aVikingTrex
Copy link

Still in my first week or two of using vim so it may just be me not understanding something. But the only feature that apparently is working for me is the syntax highlighting. Auto completions where not working until I installed deoplete (maybe i did need to do that?) but error highlighting ect does not work.
I have installed ionide and languageclient-neovim. I have python3 installed on my computer and have got both pynvim and neovim installed via pip3
Does anyone know what i have either done wrong here or if perhaps ive missed an installation step?
I have vim8.1 intalled via pacman in arch linux if this helps?

Below is my .vimrc file

filetype plugin on
call plug#begin()
Plug 'autozimu/LanguageClient-neovim', {
    \ 'branch': 'next',
    \ 'do': 'bash install.sh',
    \ }

Plug 'junegunn/fzf'

Plug 'ionide/Ionide-vim', {
      \ 'do':  'make fsautocomplete; read',
      \}
Plug 'godlygeek/tabular'
Plug 'plasticboy/vim-markdown'
Plug 'iamcco/markdown-preview.nvim', { 'do': 'cd app && npm i' }
if has('nvim')
  Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
else
   Plug 'roxma/vim-hug-neovim-rpc' 
   Plug 'roxma/nvim-yarp' 
   Plug 'Shougo/deoplete.nvim'
endif
"Plug 'vim-syntastic/syntastic'
let g:deoplete#enable_at_startup=1
call plug#end()
set laststatus=2
set tabstop=4 softtabstop=4 noexpandtab
set hidden
set number 
nnoremap <silent> K :call LanguageClient#textDocument_hover()<CR>
nnoremap <silent> gd :call LanguageClient#textDocument_definition()<CR>
nnoremap <silent> <F2> :call LanguageClient#textDocument_rename()<CR>

let g:fsharp#show_signature_on_cursor_move = 1
let g:LanguageClient_serverCommands = {
	\ 'fsharp': g:fsharp#languageserver_command
	\ }

@aVikingTrex aVikingTrex added the bug Something isn't working label Nov 16, 2019
@cannorin
Copy link
Member

When I tried several weeks ago, the Vim installation worked properly. Also, from the info you provided I believe you installed the plugin correctly. So what I suspected is the problem has something to do with the thing you are trying to open.

Did it show something like Workspace Loaded after opening a F# file?

@cannorin
Copy link
Member

btw if you are new to Vim I'd recommend to use Neovim as it has more stability and advanced features, and less complexity to use.

@Bjorn-Strom
Copy link

Bjorn-Strom commented Nov 18, 2019

I am having the same problems using Neovim.
Syntax Highlighting works but thats about it.

I am also new to Vim to may be missing something but I followed the installation guide of Lanugage server and Ionide-vim.
Config file looks very similar to aVikingTrex's.

@aVikingTrex
Copy link
Author

I actually went ahead and installed Neovim last night and ended up with the same result sadly. Bjorn appears to have experienced the same.

@cannorin
Copy link
Member

Can you give me a zip of the project you are trying to open in order to replicate it by myself?

@Bjorn-Strom
Copy link

I just created a basic F# project from the terminal.
dotnet new console --lang F# -o VimTest

@aVikingTrex
Copy link
Author

Further to what Bjorn did, I cant even get this to work outside of syntax highlighting for standalone .fsx files either

@cannorin
Copy link
Member

That may be a separate problem so let's stick to the normal fsproj for now.
Did the plugin show something like Workspace Loaded after opening a F# file?

@Bjorn-Strom
Copy link

I am not a very experienced vim user. Where should this be output?

@cannorin
Copy link
Member

It should be displayed in the status line (just below the editor).

@Bjorn-Strom
Copy link

Bjorn-Strom commented Nov 18, 2019

Possible information overload here as I am just trying everything, but:

  • In the project directory i type nvim and it displays nothing.
  • If I open the .fsproj file directly it flashes with loading snippets.
  • If I open the .fs file it flashes loading snippets and says [LC] Project root: /Users/me/VimTest

@cannorin
Copy link
Member

Currently the plugin only works when you open single .fs file at startup and it is a limitation to be resolved later (tm).

In your case, I suspect that the plugin is not actually installed (while your vimrc is correctly configured). Can you try opening a .fs file and executing :PlugInstall?

@cannorin
Copy link
Member

btw g:fsharp#languageserver_command is now deprecated and you can safely/should remove the

let g:LanguageClient_serverCommands = {
	\ 'fsharp': g:fsharp#languageserver_command
	\ }

part from your vimrc.

@Bjorn-Strom
Copy link

I removed the language client code and ran :PlugInstall on a newly created .fs file. Says Ionide-vim is already installed.

@cannorin
Copy link
Member

Hmm, strange... Unfortunately I'll be busy for next few days (exam week) and I don't have enough time to look deep into this now. Meanwhile, can you use Ionide-VSCode with VSCodeVim plugin?

@Bjorn-Strom
Copy link

It's not an emergency for me, using VSCode now.
Have a good exam!

@runbmp
Copy link
Contributor

runbmp commented Nov 21, 2019

@aVikingTrex, @Bjorn-Strom

Can you checkout pull #20 to see if that would fix your issue?

@Bjorn-Strom
Copy link

@benmp sorry for the late reply.
I tried #20 and it works! Really nice, thank you

@cannorin
Copy link
Member

@benmp nice! I'll merge the PR.
@aVikingTrex Can you also check if #20 works for you? Unfortunately I don't have a time to try it myself yet.

@aVikingTrex
Copy link
Author

aVikingTrex commented Nov 24, 2019

Thank you so much @cannorin and @benmp, that appears to all be working now. You guys are legends!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants