Fork me on GitHub
#vim
<
2016-03-14
>
lucasbradstreet04:03:11

@juhoteperi Something like that used to happen for me whenever I changed my project.clj, so even when I would change branches I'd get a lot of lag. I ended up dropping the leiningen support from vim-fireplace so that it wouldn't happen. IIRC it's reloading things to be more correct but I'd rather manage the correctness and have no lag. Not sure if this is what is going on since you use boot but it sounds very similar

dominicm13:03:43

@juhoteperi: Yeah, double check you've not installed classpath.vim. I wonder if clj-async-omni is causing it? It's possible that checking for a connection might cause something else to happen, I'd have to check. I'm assuming it's me immediately. Just in case.

juhoteperi13:03:44

No classpath.vim, not async-omni, this has been going on for longer

dominicm13:03:33

Not sure then.

dominicm13:03:12

I have the same issue.

dominicm13:03:16

But I've not rooted the cause.

juhoteperi13:03:24

I just have to try :profile and possibly do a binary search with plugins

dominicm13:03:45

I guess so. Please let me know what you figure out.

nberger13:03:48

I have the same issue, so yes, please post your findings here simple_smile

juhoteperi13:03:24

Heh, maybe it's something with fireplace

juhoteperi13:03:33

or clojure-static

dominicm13:03:46

I'm pretty sure I had it before I installed clojure-static.

dominicm13:03:50

I'm thinking it's fireplace.

dominicm13:03:56

I think it's vim-salve

dominicm13:03:32

To be fair, you might be able to remove vim salve, depending on the features you're using. I might remove it looking at what it provides.

dominicm13:03:16

I'd probably miss the auto-connect, maybe it's possible to build a stripped down version. Or something that uses neovim's job api

juhoteperi14:03:02

I don't have salve

juhoteperi14:03:22

autoconnect to .nrepl-port is built into fireplace, not salve

dominicm14:03:31

vim-salve lies .-.

juhoteperi14:03:28

Hmm... oh I have vim-leiningen

dominicm14:03:46

ah, the old name for it.

juhoteperi14:03:49

I could be wrong

dominicm14:03:56

vim-salve = vim-leiningen.

dominicm14:03:17

I wonder what removing salve will do to you.

juhoteperi14:03:20

But fireplace has some code to search for .nrepl-port

juhoteperi14:03:04

At least it provides commands to start new Lein or Boot repl, inside vim

juhoteperi14:03:09

Which I don't use

dominicm14:03:16

ah, from salve docs:

Each time |fireplace| attempts to use a repl connection, salve.vim will
try to automatically connect using target/repl-port or target/repl/repl-port.
(Fireplace itself supports the newer standard .nrepl-port.)  If none of the 3
port files exist, :Console! (see below) is invoked to automatically start a
repl.

dominicm14:03:37

I use :Console all the time, but I've got it hooked up to neovim terminals.

dominicm14:03:00

If you use gf salve claims to set that up, but there's no reason it should be, as that's built into cider-nrepl.

dominicm14:03:19

I might try remove it now, and see if my life is better

juhoteperi14:03:55

It's also somehow random or depends on something, I ran vim --startuptime profile.log react/build.boot three times, first time it took 8 seconds but subsequent starts are fast

juhoteperi14:03:29

But another file in packages repo and it takes 5 seconds again

dominicm14:03:08

I guess it caches the path.

juhoteperi14:03:17

The profiler output doesn't really show anything useful, only that opening buffers takes all the file

dominicm14:03:46

Check out: "~/.cache/vim/classpath"

juhoteperi14:03:47

Removed vim-leiningen -> fast

dominicm14:03:11

Yep. salve it is then.

dominicm14:03:18

It's the gathering of the path from the jvm.

dominicm14:03:30

Hopefully that doesn't break go-to-symbol

dominicm14:03:04

It'll depend on the fireplace implementation, it needs to be checked that it uses the nrepl middleware, instead of the naive implementation based on the jvm classpath. (Because that breaks boot)

juhoteperi14:03:12

I thought I had removed it before, I had the plugin on wrong folder even so I didn't see that I had it still

dominicm14:03:35

I stick by my thoughts: declarative plugin management is the best.

dominicm14:03:44

I'm currently considering switching to nixos full time.

juhoteperi14:03:49

submodules are declarative simple_smile

juhoteperi14:03:54

they are just declared on different place

juhoteperi14:03:30

Yes, nixos is interesting but I have near declarative package management script for Ubuntu also

dominicm14:03:43

I want the isolation too.

dominicm14:03:49

I use Arch Linux 😛

juhoteperi14:03:54

And I manage most of my system config files on dotfiles repo, but I don't need that many anyways. Nearly all config is on home folder.

dominicm14:03:12

That's true. I mean, your bundle system looks tidy. But I just add whitespace between lines. I really need to tidy up my configs. There's so many missing.

dominicm14:03:28

But currently I have a github api key in my init.vim, so I can't publish even my changes there.

juhoteperi14:03:12

That brings to mind, I have github-issues.vim installed but I have not used it. Time to remove.

juhoteperi14:03:03

And though I used to use vimagit, now I have revereted back to just git add -p

dominicm14:03:33

I think that's why i added github-issues.vim

dominicm14:03:44

I might have replaced that now.

dominicm14:03:17

I use vimagit for reviewing lots of little changes in a project, generally I use :Gstatus then press D on a file to see it's changes in a vimdiff

dominicm14:03:08

github-issues.vim does way more than I remembered. That's why I added it. I've got my own omnicomplete now, which is async, so actually fast.

juhoteperi16:03:22

Somewhat related to Vim; damn those new ThinkPads looks pathetic compared to X220 😕

dominicm19:03:47

I use an X230.

dominicm19:03:02

Some people hate the chiclet though.

juhoteperi19:03:38

I could live with chiclet and bad layout but there are plenty of other problems, t460s has small integrated battery, 20GB max memory and dim screen and flickering backlight

juhoteperi19:03:52

Still waiting for proper t460p reviews

juhoteperi19:03:38

Removing vim-leiningen seems to have solved my slow opening issues. And I noticed that I still had YCM left-over on my desktop and removing that fixed deoplete.

juhoteperi20:03:00

And automatic nrepl connection to Boot and Lein works fine

dominicm20:03:15

I'm looking at going ergodox. I think something that small might be able to comfortably sit beside my laptop most of the time.

dominicm20:03:23

I don't mind the ergodox though tbh.

nberger20:03:51

I did the same, removed vim-leiningen, it fixed the issue and (at least from boot) nrepl connection works fine

dominicm20:03:52

That's awesome. RE vim-leiningen. I've commented it out for now, I'm going to see if I miss anything. I fear that gf might break.

dominicm20:03:59

vim-fireplace?! 😉

juhoteperi20:03:18

I have Ergodox Ez, but I haven't had yet time to customize keymap so I'm not using it

nberger20:03:24

who said vim-fireplace? 😛 sorry, I mean vim-leiningen

juhoteperi20:03:36

I don't like the default keymap much

dominicm20:03:36

@juhoteperi: I'm going to buy a 3d printer and do it all myself. Well, if I put together a good clojure layout, I'll forward it to you.

dominicm20:03:48

Or, I suppose you want a european layout.

juhoteperi20:03:51

Yeah, though it is not necessary that hardware/firmware layout is European, software will map it. But it is probably necessary to thing about layout being used when designing it.

juhoteperi20:03:42

The default layout in EZ is strange: http://ergodox-ez.com/ergodox_ez_keymap_highres.png it has two sets of arrow keys 😄

dominicm20:03:46

Yeah, I suppose that makes sense for most users. I think the coder layer toggle is good.

dominicm20:03:11

But I might be inclined to remap those arrow keys to parens or something for programming.

leov20:03:30

@dominicm: thank you for the advice. will do next time

dominicm20:03:48

@leov: No problem. Although this channel is very busy today. How strange. 😛

dominicm20:03:36

@juhoteperi: If you decide to have a play, it's super easy to install nix the package manager, locally only. It's really cool.

dominicm21:03:35

I can confirm that removing vim-salve loses the ability to do gf

dominicm21:03:51

But, er.. I have a custom mapping for it.

dominicm21:03:33

:Djump {symbol} still works.

dominicm21:03:51

A great mapping for it: nmap gs <Plug>FireplaceDjump

dominicm21:03:39

I couldn't deal with the default mapping. But yeah. That will still work on the namespace, so gf isn't something to miss.