# Juila + Vim

**URL:** <https://discourse.julialang.org/t/juila-vim/29817>\
**Category:** Tooling\
**Created:** [October 12, 2019, 2:03pm UTC](https://discourse.julialang.org/t/juila-vim/29817 "2019-10-12T14:03:23Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![sstadick](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sstadick/32/10776_2.png) [@sstadick](https://discourse.julialang.org/u/sstadick)\
**Post date:** [October 12, 2019, 2:03pm UTC](https://discourse.julialang.org/t/juila-vim/29817/1 "2019-10-12T14:03:23Z")

</div>

Hello! Does anyone have a good working setup of Julia and vim? I’m using the LanguageServer, but it seems to have a lot of issues / is slow and crashes a lot. Are there any alternatives?

Side question, what’s your workflow look like with vim? Repl on the side? A jupyter notebook running?

---

<div class="post-metadata">

**Author:** ![DoktorMike](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/doktormike/32/2736_2.png) [@DoktorMike](https://discourse.julialang.org/u/DoktorMike)\
**Post date:** [October 12, 2019, 2:09pm UTC](https://discourse.julialang.org/t/juila-vim/29817/2 "2019-10-12T14:09:09Z")

</div>

I use vim slime to push code through gnu screen. This works well for me. The language server integration I never got working satisfactory. Like you said: crashes a lot and is in general buggy at least on my system. Ultisnips has some nice Julia snippets included.

---

<div class="post-metadata">

**Author:** ![milesf](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/milesf/32/9289_2.png) [@milesf](https://discourse.julialang.org/u/milesf)\
**Post date:** [October 12, 2019, 3:52pm UTC](https://discourse.julialang.org/t/juila-vim/29817/3 "2019-10-12T15:52:20Z")

</div>

I’ve tried switching back to vim recently, after becoming frustrated by Atom’s partial macro support, but did not have a good experience with autocomplete. Any text entry would spike one of my CPU cores to 100% for a few seconds and spin up my laptop fan as if I was running benchmarks. Not great for battery life.

I experienced this issue with both @ExpandingMan’s [config](https://github.com/ExpandingMan/dotfiles/blob/master/.config/nvim/init.vim) and the suggested config on the LanguageServer.jl [wiki](https://github.com/julia-vscode/LanguageServer.jl/wiki/Vim-and-Neovim).

Atom also occasionally has similar tagging/autocomplete performance issues, but is more likely to get into a good state with responsive tagging that works mostly as expected. It’s not perfect though, and still misses some completions or lags sometimes.

Compromise for me now is to use Atom (with vim mode) for most development, and launch real vim if I need to make a more involved edit that would benefit from macros or other plugins. This workflow is not ideal, and I hope we can find a better solution in this thread.

---

<div class="post-metadata">

**Author:** ![zgornel](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/zgornel/32/217487_2.png) [@zgornel](https://discourse.julialang.org/u/zgornel)\
**Post date:** [October 12, 2019, 3:54pm UTC](https://discourse.julialang.org/t/juila-vim/29817/4 "2019-10-12T15:54:35Z")

</div>

I use the `julia-vim` plugin; as for flow, I have (i use i3wm as window manager):

- 1 tmux session with several windows, each window with a vim instance, multiple files edited pertinent to individual packages
- 1 tmux session (floating i3 window), multiple windows for REPL instances, multiple panes for code that
- 1 tmux session, multiple windows, for documentation/quick searches/etc.

Screenshot, just for laughs: [Friday's night coding sessions. by zgornel on DeviantArt](https://www.deviantart.com/zgornel/art/Friday-s-night-coding-sessions--766000842)

---

<div class="post-metadata">

**Author:** ![sstadick](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sstadick/32/10776_2.png) [@sstadick](https://discourse.julialang.org/u/sstadick)\
**Post date:** [October 12, 2019, 5:09pm UTC](https://discourse.julialang.org/t/juila-vim/29817/5 "2019-10-12T17:09:36Z")

</div>

Nice! I like the screenshot!

---

<div class="post-metadata">

**Author:** ![sstadick](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sstadick/32/10776_2.png) [@sstadick](https://discourse.julialang.org/u/sstadick)\
**Post date:** [October 12, 2019, 5:13pm UTC](https://discourse.julialang.org/t/juila-vim/29817/6 "2019-10-12T17:13:03Z")

</div>

I haven’t tried @ExpandingMan’s config, I’ll have to give that a shot. The only features I really want are syntax highlighting and syntax checking. Autocomplete is nice to have, but I can live without if it means making vim usable.

---

<div class="post-metadata">

**Author:** ![bvz](https://avatars.discourse-cdn.com/v4/letter/b/b5e925/32.png) [@bvz](https://discourse.julialang.org/u/bvz)\
**Post date:** [March 11, 2020, 5:27am UTC](https://discourse.julialang.org/t/juila-vim/29817/7 "2020-03-11T05:27:27Z")

</div>

I’m facing this exact issue.

I’ve been “spoiled” with [NVimR](https://github.com/jalvesaq/Nvim-R) since my current course is focusing on R.

There are three features it has in particular that I as a novice appreciate and think would be valuable for coders of all levels:

1. Documentaion lookup from the source code (put the cursor over any function/method and do a hotkey combination and you get the lookup for the object without leaving vim)
2. Object browser
3. Running code directly (I see that this should be somewhat replicable with [vim-slime](https://github.com/jpalardy/vim-slime) but haven’t tried it myself)

---

<div class="post-metadata">

**Author:** ![c42f](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/c42f/32/52842_2.png) [@c42f](https://discourse.julialang.org/u/c42f)\
**Post date:** [March 11, 2020, 7:29am UTC](https://discourse.julialang.org/t/juila-vim/29817/8 "2020-03-11T07:29:04Z")

</div>

So far I’ve found the `julia-vim` plugin is the only thing which works 100% reliably and without any noticeable performance issues. With julia-vim you can get Base documentation with the `K` binding.

I haven’t had luck yet with setting up LanguageServer. The most recent and reasonable-looking config I’ve found was @joshbode’s config from here: [Omni completion broken with LanguageClient-neovim · Issue #261 · julia-vscode/LanguageServer.jl · GitHub](https://github.com/julia-vscode/LanguageServer.jl/issues/261#issuecomment-419693635)

Even with that as a guide I found setup surprisingly difficult (eg I think LanguageServer is only compatible with Julia 1.2 right now) and for the moment I’m back to using julia-vim.

---

<div class="post-metadata">

**Author:** ![fverdugo](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fverdugo/32/9446_2.png) [@fverdugo](https://discourse.julialang.org/u/fverdugo)\
**Post date:** [March 11, 2020, 11:35am UTC](https://discourse.julialang.org/t/juila-vim/29817/9 "2020-03-11T11:35:58Z")

</div>

I am quite happy with julia-vim. It does a perfect job with the latex to unicode conversion of special symbols.

Regarding auto-completion, the built-in auto-completion of vim (ctrl+N) works reasonably well if you have opened some files of your project (I assume that it looks among the words in the opened buffers). So far, this has been more than enough for my use cases. But, of course, a more “smart” auto-completion machinery would be also nice.

---

<div class="post-metadata">

**Author:** ![thehalfspace](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/thehalfspace/32/7217_2.png) [@thehalfspace](https://discourse.julialang.org/u/thehalfspace)\
**Post date:** [April 9, 2020, 6:28pm UTC](https://discourse.julialang.org/t/juila-vim/29817/10 "2020-04-09T18:28:42Z")

</div>

I’ve using julia-vim for some time now. I recently realized that my scrolling has become super slow when working on .jl files. I’m pretty sure it has something to do with julia-vim since it works alright if I delete that plugin. I’m on mac btw, but similar issues in my linux system as well.

Is there anything where I just have the syntax highlighting? I can live without autocomplete and latex-unicode conversion for now.

---

<div class="post-metadata">

**Author:** ![AlexisRenchon](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/alexisrenchon/32/13328_2.png) [@AlexisRenchon](https://discourse.julialang.org/u/AlexisRenchon)\
**Post date:** [April 9, 2020, 9:00pm UTC](https://discourse.julialang.org/t/juila-vim/29817/11 "2020-04-09T21:00:11Z")

</div>

I use vimteractive, google it! It makes a nice Julia + VIM IDE

---

<div class="post-metadata">

**Author:** ![c42f](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/c42f/32/52842_2.png) [@c42f](https://discourse.julialang.org/u/c42f)\
**Post date:** [April 10, 2020, 3:19am UTC](https://discourse.julialang.org/t/juila-vim/29817/12 "2020-04-10T03:19:30Z")

</div>

`julia-vim` is about as minimal as it gets, I suspect, and it could well be the syntax highlighting which causes the difficulty because writing efficient syntax patterns isn’t always easy. I’ve never had any trouble though; all I know is that it works really well on my linux machine.

You could report the issue on the `julia-vim` repo and the author might be able to help.

---

<div class="post-metadata">

**Author:** ![caleb-allen](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/caleb-allen/32/14054_2.png) [@caleb-allen](https://discourse.julialang.org/u/caleb-allen)\
**Post date:** [April 13, 2020, 7:53pm UTC](https://discourse.julialang.org/t/juila-vim/29817/13 "2020-04-13T19:53:48Z")

</div>

Vimteractive looks pretty neat! I’ve been looking for a more natural editor + REPL flow, I’ll give this a try!

---

<div class="post-metadata">

**Author:** ![PetrKryslUCSD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/petrkryslucsd/32/215825_2.png) [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Post date:** [April 13, 2020, 8:29pm UTC](https://discourse.julialang.org/t/juila-vim/29817/14 "2020-04-13T20:29:43Z")

</div>

More natural than what?

---

<div class="post-metadata">

**Author:** ![caleb-allen](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/caleb-allen/32/14054_2.png) [@caleb-allen](https://discourse.julialang.org/u/caleb-allen)\
**Post date:** [April 13, 2020, 8:39pm UTC](https://discourse.julialang.org/t/juila-vim/29817/15 "2020-04-13T20:39:14Z")

</div>

Well, more natural than my crude poke, copy, and paste flow. I’ve only recently started exploring Julia and I’m trying to be intentional about the REPL habits I develop, coming from a mobile software background which did not emphasize REPL/exploration based development.

Revise has been wonderful from the REPL side. I’ve bounced around editors, though, so vimteractive piques my interest.

Maybe I’ll end up just with `julia-vim` and the REPL?

---

<div class="post-metadata">

**Author:** ![ppalmes](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ppalmes/32/6838_2.png) [@ppalmes](https://discourse.julialang.org/u/ppalmes)\
**Post date:** [May 26, 2020, 1:31am UTC](https://discourse.julialang.org/t/juila-vim/29817/16 "2020-05-26T01:31:53Z")

</div>

julia-vim with slimux should be good enough. add plugins to tmux such as continuum and you can go back to tmux sessions even after reboot.

---

<div class="post-metadata">

**Author:** ![qwerytyui1234](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/qwerytyui1234/32/31952_2.png) [@qwerytyui1234](https://discourse.julialang.org/u/qwerytyui1234)\
**Post date:** [June 11, 2020, 5:09am UTC](https://discourse.julialang.org/t/juila-vim/29817/17 "2020-06-11T05:09:12Z")

</div>

Sorry to bump an old thread, but I recently switched to Vim and I am also experiencing the same thing. If I take out the syntax highlighting, it becomes fast, but as soon as I add syntax highlighting, the terminal becomes laggy and slow as hell. Have you found a solution to this predicament yet?

edit: For now, I’m just using it with disabled syntax highlighting, but I would love to get it back. If anybody has any ideas, it would be very much appreciated. If not, I’ll try to open an issue on Github or something.

---

<div class="post-metadata">

**Author:** ![thehalfspace](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/thehalfspace/32/7217_2.png) [@thehalfspace](https://discourse.julialang.org/u/thehalfspace)\
**Post date:** [June 11, 2020, 4:45pm UTC](https://discourse.julialang.org/t/juila-vim/29817/18 "2020-06-11T16:45:34Z")

</div>

I didn’t find a permanent solution yet. It might just have been my macos.

What worked for me was using Alacritty terminal emulator and getting rid of some of my superfluous vim plugins. But with alacritty I need to use tmux, which I am not a big fan of.

Which os do you use? I suggest reworking your vimrc and terminal emulator to see if it works.

Also, I never got around to opening a github issue, but go for it, I would be interested in a better solution as well.

---

<div class="post-metadata">

**Author:** ![mbaz](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mbaz/32/17295_2.png) [@mbaz](https://discourse.julialang.org/u/mbaz)\
**Post date:** [June 11, 2020, 4:58pm UTC](https://discourse.julialang.org/t/juila-vim/29817/19 "2020-06-11T16:58:22Z")

</div>

> [@qwerytyui1234](#):
>
> If I take out the syntax highlighting, it becomes fast,

As a data point, I use vim and vim-julia on Linux and have no problems at all with speed. Have you tried using gvim instead of running vim on the terminal?

> [@thehalfspace](#):
>
> with alacritty I need to use tmux

If all you need is tabs, I recommend [tabbed](https://tools.suckless.org/tabbed/). It’s very lightweight and just works.

---

<div class="post-metadata">

**Author:** ![thehalfspace](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/thehalfspace/32/7217_2.png) [@thehalfspace](https://discourse.julialang.org/u/thehalfspace)\
**Post date:** [June 11, 2020, 5:08pm UTC](https://discourse.julialang.org/t/juila-vim/29817/20 "2020-06-11T17:08:39Z")

</div>

Thanks :), will check it out.

[Next page](https://discourse.julialang.org/t/juila-vim/29817.md?page=2)
